*----------------------------------------------------------------- * GENERATED APPLICATION: CALLED BATCH *----------------------------------------------------------------- IDENTIFICATION DIVISION. PROGRAM-ID. KGGSM1. AUTHOR. NONE INSTALLATION. NONE DATE WRITTEN. 02.06.2000. DATE COMPILED. ENVIRONMENT DIVISION. CONFIGURATION SECTION. SPECIAL-NAMES. DECIMAL-POINT IS COMMA. *----------------------------------------------------------------- * APPLICATION NAME : KGGSM1 * APPLICATION TYPE : CALLEDBATCH * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:40:58 * GENERATION SYSTEM : MVSCICS * GENERATION DATE : 02.06.2000 * GENERATION TIME : 18:16:12 * GENERATION OPTIONS : * ANSISQL(NO) * CICSDBCS(NO) * COMMLVL(4) * CONTABLE(ELACNTUR) * DATA(31) * DEBUGTRACE(NO) * ENDCOMMAREA(NO) * FOLD(NO) * GENRET(NO) * INEDIT(ALL) * INITADDWS(YES) * INITRECD(YES) * LINEINFO(NO) * MATH(COBOL) * NUMOVFL(YES) * PREPFILE(YES) * PRINTDEST(EZEP) * SPZERO(NO) * SYNCDXFR(YES) * SYSCODES(YES) * TARGNLS(ENU) * TRACE() * TRANSID(DBSV,) * TWAOFF(0) * USERID(DGNM) * VALIDMIX(YES) * WORKDB(AUX) * * PROLOGUE: * *----------------------------------------------------------------- INPUT-OUTPUT SECTION. DATA DIVISION. WORKING-STORAGE SECTION. * RTS APPLICATION PROFILE BLOCK 01 EZEAPP-PROFILE SYNCHRONIZED. 05 FILLER PIC X(8) VALUE "ELARHAPP". 05 EZEAPP-APPL-NAME PIC X(8) VALUE "KGGSM1". 05 EZEAPP-PGM-VERSION. 10 EZEAPP-GEN-DATE PIC X(8) VALUE "20000615". 10 EZEAPP-GEN-TIME PIC X(8) VALUE "18162935". 05 EZEAPP-RTS-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-GEN-VERSION PIC X(16) VALUE "040301". 05 EZEAPP-COB-SYS PIC X(8) VALUE "MVSCICS". 05 EZEAPP-CALLER-PROFILE USAGE IS POINTER VALUE NULL. 05 EZEAPP-EZE-WORDS-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-CURS-BLK-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-DLI-SCAN-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-MSP-IDENT-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-SPA-LEN PIC S9(9) COMP VALUE +0. 05 EZEAPP-MAX-MSG-LEN PIC S9(9) COMP VALUE +0. 05 EZEAPP-WSR-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-DB-IO-LEN PIC S9(9) COMP VALUE +65535. 05 EZEAPP-PARM-VAL-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-1ST-MAP-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-PSBNAME PIC X(8) VALUE SPACES. 05 EZEAPP-PCB-CNT PIC S9(4) COMP VALUE +0. 05 EZEAPP-MS-PCB-NO PIC S9(4) COMP VALUE ZERO. 05 EZEAPP-WK-PCB-NO PIC S9(4) COMP VALUE +0. 05 EZEAPP-ERRDEST PIC X(8) VALUE SPACES. 05 EZEAPP-LOG-ID PIC X(1) VALUE LOW-VALUES. 05 EZEAPP-MSP-PROGRAM PIC X(8) VALUE SPACES. 05 EZEAPP-MAP-GROUP PIC X(8) VALUE SPACES. 05 EZEAPP-HELP-MAP-GROUP PIC X(8) VALUE SPACES. 05 EZEAPP-HELP-PF-KEY PIC X(2) VALUE "01". 05 EZEAPP-BYPASS-PF-KEYS. 10 FILLER PIC X(10) VALUE SPACES. 05 FILLER REDEFINES EZEAPP-BYPASS-PF-KEYS. 10 EZEAPP-BYPASS-PF-KEY PIC X(2) OCCURS 5 TIMES. 05 EZEAPP-MSG-FILE-ID PIC X(4) VALUE SPACES. 05 EZEAPP-MS-DB-TYPE PIC X(1) VALUE "5". 05 EZEAPP-WK-DB-TYPE PIC X(1) VALUE "3". 05 EZEAPP-ADF-SPA PIC X(1) VALUE "N". 05 EZEAPP-APPL-TYPE PIC X(1) VALUE "4". 05 EZEAPP-EXECMODE PIC X(1) VALUE "1". 05 EZEAPP-SCAN-IO-PCB PIC X(1) VALUE "N". 05 EZEAPP-PF1-12-IS-PF13-24 PIC X(1) VALUE "Y". 05 EZEAPP-NLS-CODE PIC X(3) VALUE "ENU". 05 EZEAPP-CURRENCY-SYMBOL PIC X(1) VALUE "T". 05 EZEAPP-DECIMAL-SYMBOL PIC X(1) VALUE ",". 05 EZEAPP-NUM-SEP-SYMBOL PIC X(1) VALUE ".". 05 EZEAPP-MATH PIC X(5) VALUE "COBOL". 05 EZEAPP-SYSTEM-RTN-CODES PIC X(1) VALUE "Y". 05 EZEAPP-ENTRY-FUNCTION PIC X(2) VALUE LOW-VALUES. 05 EZEAPP-MS-RTB-ADDRESS USAGE IS POINTER VALUE NULL. 05 EZEAPP-TBK-STACK-SIZE PIC S9(9) COMP VALUE +0. 05 FILLER PIC X(8) VALUE LOW-VALUES. 05 EZEAPP-FAST-PATH-SW PIC X(1) VALUE "N". 05 EZEAPP-RECOVERY-SW PIC X(1) VALUE "N". 05 FILLER PIC X(1) VALUE LOW-VALUES. 05 EZEAPP-EZEDESTP-CHANGED PIC X(1) VALUE "N". 05 EZEAPP-LINK-TYPE PIC X(1) VALUE "4". 05 EZEAPP-PARM-FORM PIC X(1) VALUE "1". 05 EZEAPP-CURS-BLK-CNT PIC S9(4) COMP VALUE +1. 05 EZEAPP-TWA-LENGTH PIC S9(9) COMP VALUE +0. 05 EZEAPP-TWA-ADDRESS USAGE IS POINTER VALUE NULL. 05 EZEAPP-TWA-USER-LENGTH PIC S9(9) COMP VALUE 0. 05 EZEAPP-MAX-SSA-LENGTH PIC S9(9) COMP VALUE +0. 05 EZEAPP-LTB-ARRAY-ADDRESS USAGE IS POINTER VALUE NULL. 05 EZEAPP-ENTRY-COMMAREA-PTR USAGE IS POINTER VALUE NULLS. 05 FILLER PIC X(1) VALUE SPACES. 05 EZEAPP-NEED-ENDB PIC X(1) VALUE "N". 05 EZEAPP-BAD-RESP PIC X(1) VALUE "N". 05 FILLER PIC X(1) VALUE SPACES. 05 EZEAPP-SYNC-XFERS-SW PIC X(1) VALUE "N". 05 EZEAPP-SYNC-DXFRS-SW PIC X(1) VALUE "Y". 05 EZEAPP-STATIC-CALLS PIC X(1) VALUE "N". 05 EZEAPP-INEDIT-UNP-SW PIC X(1) VALUE "N". 05 EZEAPP-MAX-DB-IOAREA PIC S9(9) COMP VALUE +32767. 05 EZEAPP-LAST-MAPBUF-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-FIRST-MAPBUF-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-ROWS-USED-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-MAPG-MOD-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-HELPG-MOD-PTR USAGE IS POINTER VALUE NULL. 05 EZEAPP-CURRENT-RSCT-IDX PIC S9(9) COMP VALUE +0. 05 EZEAPP-CURRENT-HELP-MAP PIC X(8) VALUE SPACES. 05 EZEAPP-EZEDESTP. 10 EZEDESTP PIC X(65) VALUE SPACES. 05 EZEAPP-OPEN-NEW-DESTP PIC X(1) VALUE "N". 05 EZEAPP-EZEDESTP-DIFF PIC X(1) VALUE "N". 05 EZEAPP-USES-SQL PIC X(1) VALUE "Y". 05 EZEAPP-XFER-MAP PIC X(8) VALUE LOW-VALUES. 05 FILLER PIC X(21) VALUE LOW-VALUES. * RTS ERROR HANDLING REQUEST BLOCK COPY ELAEHERR. * RTS SQL ERROR HANDLING REQUEST BLOCK COPY ELA2HERR. 01 EZECICS-TMP-2BYTE-COMP PIC S9(4) COMP VALUE ZERO. * RTS MNEMONICS COPY ELARHMNE. * RTS REQUEST BLOCK COPY ELARHRRB. * DISPLAY SERVICES REQUEST BLOCK COPY ELARHFMR. * EZE SPECIAL FUNCTION WORDS 01 EZEWORDS. 05 EZEEZE-ID PIC X(8) VALUE "ELARHEZE". 05 EZEWORDS-LL PIC S9(9) COMP VALUE +334. 05 EZEWORDS-I. 10 EZEAID PIC X(2) VALUE SPACES. 88 EZEAID-ENTER VALUE " ". 88 EZEAID-CLEAR VALUE "CL". 88 EZEAID-PAKEY VALUE "P1" "P2" "P3". 88 EZEAID-PA1 VALUE "P1". 88 EZEAID-PA2 VALUE "P2". 88 EZEAID-PA3 VALUE "P3". 10 EZEAID-BYPASS-SW PIC X(1) VALUE SPACES. 88 EZEAID-BYPASS VALUE "Y". 88 EZEAID-NO-BYPASS VALUE "N". 10 EZEAID-HELP-SW PIC X(1) VALUE SPACES. 88 EZEAID-HELP VALUE "Y". 88 EZEAID-NO-HELP VALUE "N". 10 EZEAPP PIC X(8) VALUE SPACES. 10 EZECNVCM PIC 9(1) VALUE 0. 88 EZECNVCM-NOCOMMIT VALUE 0. 88 EZECNVCM-COMMIT VALUE 1. 10 EZEDLTRM REDEFINES EZECNVCM PIC 9(1). 10 FILLER PIC X(5) VALUE LOW-VALUES. 10 EZELOC PIC X(8) VALUE SPACES. 10 EZEDLCER PIC X(2) VALUE "00". 10 EZEDLCON PIC X(2) VALUE "00". 10 FILLER PIC 9(7) VALUE ZEROES. 10 EZEFEC PIC 9(1) VALUE ZEROES. 88 EZEFEC-TERMINATE VALUE 0. 88 EZEFEC-CONTINUE VALUE 1. 10 EZEDLERR PIC 9(1) VALUE ZEROES. 88 EZEDLERR-TERMINATE VALUE 0. 88 EZEDLERR-CONTINUE VALUE 1. 10 EZESQISL PIC 9(1) VALUE ZEROES. 10 EZEMNO PIC S9(4) COMP VALUE ZEROES. 88 EZEMNO-ERROR VALUES 1 THRU 9998 -9999 THRU -1. 88 EZEMNO-NO-ERROR VALUE 0. 88 EZEMNO-RE-CONVERSE VALUE 9999. 10 EZEMNO-MSG-FILE-SW PIC X(1) VALUE "N". 88 EZEMNO-APP-MSG-FILE VALUE "Y". 88 EZEMNO-SYS-MSG-FILE VALUE "N". 10 EZEMSG PIC X(78). 88 EZEMSG-SPACES VALUE SPACES. 10 EZEOVER PIC 9(1) VALUE ZEROES. 88 EZEOVER-DEFAULT VALUE 0. 88 EZEOVER-TERMINATE VALUE 1. 88 EZEOVER-CONTINUE VALUE 2. 10 EZEOVERS PIC 9(1) VALUE ZEROES. 10 EZERCODE PIC S9(9) COMP VALUE ZEROES. 10 EZERT2 PIC X(2) VALUE SPACES. 10 EZERT8. 15 EZERT8FS. 20 EZERT8FH PIC 9(1). 20 EZERT8FL PIC 9(1). 15 EZERT8VS. 20 EZERT8VR PIC 9(2). 20 EZERT8VF PIC 9(1). 20 EZERT8VB PIC 9(3). 10 EZERT8-CICS REDEFINES EZERT8. 15 EZERT8-RESP PIC 9(4). 15 EZERT8-RESP2 PIC 9(4). 10 EZESEGM PIC 9(1) VALUE 0. 88 EZESEGM-NONSEGMENT VALUE 0. 88 EZESEGM-SEGMENTED VALUE 1. 88 EZESEGM-DEFINED VALUE 0. 10 EZECONVT PIC X(8) VALUE SPACES. 10 EZETST PIC S9(4) COMP VALUE ZEROES. 10 EZETST2 PIC S9(4) COMP VALUE ZEROES. 10 EZESQLCA. 15 EZESQNAM PIC X(8) VALUE SPACES. 15 EZESQABC PIC S9(9) COMP VALUE ZEROES. 15 EZESQCOD PIC S9(9) COMP VALUE ZEROES. 15 EZESQRRL PIC S9(4) COMP VALUE ZEROES. 15 EZESQRRM. 20 EZESQRET PIC X OCCURS 70 TIMES INDEXED BY EZESQSUB. 15 EZESQRRP. 20 EZESQRPP PIC X(3) VALUE SPACES. 20 EZESQRVM PIC X(5) VALUE SPACES. 15 EZESQRD1 PIC S9(9) COMP VALUE ZEROES. 15 EZESQRD2 PIC S9(9) COMP VALUE ZEROES. 15 EZESQRD3 PIC S9(9) COMP VALUE ZEROES. 15 EZESQRD4 PIC S9(9) COMP VALUE ZEROES. 15 EZESQRD5 PIC S9(9) COMP VALUE ZEROES. 15 EZESQRD6 PIC S9(9) COMP VALUE ZEROES. 15 FILLER PIC X(1) VALUE SPACES. 15 EZESQWN1 PIC X(1) VALUE SPACES. 15 FILLER PIC X(4) VALUE SPACES. 15 EZESQWN6 PIC X(1) VALUE SPACES. 15 FILLER PIC X(9) VALUE SPACES. 10 EZEDL-PCB-INFO. 15 EZEDLDBD PIC X(8) VALUE SPACES. 15 EZEDLLEV PIC 9(2) VALUE ZEROES. 15 EZEDLSTC PIC X(2) VALUE SPACES. 15 EZEDLPRO PIC X(4) VALUE SPACES. 15 FILLER PIC X(4) VALUE SPACES. 15 EZEDLSEG PIC X(8) VALUE SPACES. 15 EZEDLKYL PIC S9(4) COMP VALUE 1. 15 EZEDLSSG PIC S9(4) COMP VALUE ZEROES. 05 EZEMNO-LOOKED-UP-SW PIC X(1) VALUE "N". 88 EZEMNO-LOOKED-UP VALUE "Y". 88 EZEMNO-NOT-LOOKED-UP VALUE "N". 05 EZESYS PIC X(8) VALUE "MVSCICS". 88 EZESYS-IMSVS VALUE "IMSVS". 88 EZESYS-IMSBMP VALUE "IMSBMP". 88 EZESYS-MVSBATCH VALUE "MVSBATCH". 88 EZESYS-MVSCICS VALUE "MVSCICS". 88 EZESYS-OS2CICS VALUE "OS2CICS". 88 EZESYS-TSO VALUE "TSO". 88 EZESYS-VSECICS VALUE "VSECICS". 88 EZESYS-VSEBATCH VALUE "VSEBATCH". 88 EZESYS-OS400 VALUE "OS400". 88 EZESYS-OS2GUI VALUE "OS2GUI". 88 EZESYS-OS2 VALUE "OS2". 88 EZESYS-AIX VALUE "AIX". 88 EZESYS-WINGUI VALUE "WINGUI". 88 EZESYS-AIXCICS VALUE "AIXCICS". 88 EZESYS-VMCMS VALUE "VMCMS". 88 EZESYS-VMBATCH VALUE "VMBATCH". 88 EZESYS-HP VALUE "HP". 88 EZESYS-ITF VALUE "ITF". 88 EZESYS-NTCICS VALUE "NTCICS". 88 EZESYS-WINNT VALUE "WINNT". 05 FILLER PIC X(2) VALUE LOW-VALUES. 05 EZEDLKEY. 10 EZEDLKYC PIC X(1). * FIXED WORK FIELDS COPY ELARHWRK. 01 EZECTL-CALL-FIELDS. 05 EZECTL-RETURN-CODE PIC S9(4) COMP. 05 EZECTL-INDEX PIC S9(4) COMP. 05 EZECTL-HOLD-EZEDLPSB PIC X(8). 05 EZECTL-HOLD-CTL-MODE PIC X(1). 05 EZECTL-HOLD-CTL-REQUEST PIC X(1). 01 EZECTL-CONTROL-FIELDS. 05 EZECTL-IN-EZETERMINATE-FLAG PIC X(1) VALUE "N". 88 EZECTL-IN-EZETERMINATE VALUE "Y". 88 EZECTL-NOT-IN-EZETERMINATE VALUE "N". 01 EZECTL-FUNCTION-RETURN-CODE. 05 EZECTL-FUNCTION-RC-BIN-2 PIC S9(4) COMP. 05 EZECTL-FUNCTION-RC-BIN-4 PIC S9(9) COMP. 05 EZECTL-FUNCTION-RC-NUM-8 PIC 9(8). *----------------------------------------------------------------- * EXTERNAL PARAMETER CONTROL BLOCK *----------------------------------------------------------------- 01 EZEPARM-VALIDATION. 05 EZEPARM-ID PIC X(8) VALUE "ELARHPRM". 05 EZEPARM-COUNT PIC S9(4) COMP VALUE +3. 05 EZEPARM-TYPES. 10 FILLER PIC X(1) VALUE "2". 10 FILLER PIC X(1) VALUE "4". 10 FILLER PIC X(1) VALUE "4". *----------------------------------------------------------------- * WORKING STORAGE RECORD VDBCOMMON *----------------------------------------------------------------- 01 EZEWS-VDBCOMMON-GP. 02 EZEWS-ID PIC X(8) VALUE "ELAASGWS". 02 EZEWS-VDBCOMMON-LL PIC S9(8) COMP VALUE +158. 02 FILLER PIC X(2) VALUE SPACES. 02 FILLER PIC X(18) VALUE "VDBCOMMON". *----------------------------------------------------------------- * RECORD NAME : VDBCOMMON * FILE ORGANIZATION : WORKSTOR * MODIFICATION DATE : 01.06.2000 * MODIFICATION TIME : 10:48:58 * RECORD PROLOGUE : * ************************************************************ * * Record : VDBCOMMON * * * * Function : Database information and control record * * to be used in the application itself * * ************************************************************ *----------------------------------------------------------------- 02 VDBCOMMON. * General Purpose Index 05 UINDEX1 PIC S9(4) VALUE ZERO USAGE COMP. * General Purpose Index 05 UINDEX2 PIC S9(4) VALUE ZERO USAGE COMP. * General Purpose Index 05 UINDEX3 PIC S9(4) VALUE ZERO USAGE COMP. * Genral Purpose Index 05 UINDEX4 PIC S9(4) VALUE ZERO USAGE COMP. * General Purpose Index 05 UINDEX5 PIC S9(4) VALUE ZERO USAGE COMP. * Last Update Date Timestamp 05 ULAST-UPDATE-TS PIC X(26) VALUE SPACES USAGE DISPLAY. * Application Name 05 UAPPLNAM PIC X(7) VALUE SPACES USAGE DISPLAY. 05 EZE-REDEF-1 REDEFINES UAPPLNAM. * Application Prefix 06 UAPPLPFX PIC X(3) USAGE DISPLAY. 06 EZE-REDEF-2 REDEFINES UAPPLPFX. * Project/System ID - 1st Char 07 USYSID1 PIC X(1) USAGE DISPLAY. * Application ID 07 UAPPLID PIC X(2) USAGE DISPLAY. * Application Suffix 06 UAPPLSFX PIC X(4) USAGE DISPLAY. * Process Name 05 UPROCNAM PIC X(30) VALUE SPACES USAGE DISPLAY. * Table Name 05 UTABLNAM PIC X(30) VALUE SPACES USAGE DISPLAY. * SQL Row Record Name 05 USQLREC PIC X(18) VALUE SPACES USAGE DISPLAY. * NRF Flag 05 UNRF PIC X(1) VALUE SPACES USAGE DISPLAY. * Duplicate Key Flag 05 UDUP PIC X(1) VALUE SPACES USAGE DISPLAY. * SQL Number Item 05 USQLNUM PIC S9(3) VALUE ZERO USAGE DISPLAY. * SQL Code (CHA) 05 UEZESQCD PIC X(4) VALUE SPACES USAGE DISPLAY. 05 EZE-REDEF-3 REDEFINES UEZESQCD. * Number Sign 06 USIGN PIC X(1) USAGE DISPLAY. * SQL Code Insert 06 USQLCHA PIC X(3) USAGE DISPLAY. 02 FILLER PIC X(4) VALUE "*END". EXEC SQL INCLUDE SQLCA END-EXEC. * SQL ITEM REQUEST BLOCK COPY ELASHSQI. *----------------------------------------------------------------- * RECORD NAME = KATSAYI * TABLE NAME = BORDRO.KATSAYI * SQL ROW ITEM SQL COLUMN * DONEM_TARIH DONEM_TARIH * MAAS_KSAYI MAAS_KSAYI * TABAN_AY_KSAYI TABAN_AY_KSAYI * YAN_ODE_KSAYI YAN_ODE_KSAYI * VRG_DILIM_1 VRG_DILIM_1 * VRG_ORAN_1 VRG_ORAN_1 * VRG_DILIM_2 VRG_DILIM_1 * VRG_ORAN_2 VRG_ORAN_1 * VRG_DILIM_3 VRG_DILIM_1 * VRG_ORAN_3 VRG_ORAN_1 * VRG_DILIM_4 VRG_DILIM_1 * VRG_ORAN_4 VRG_ORAN_1 * VRG_DILIM_5 VRG_DILIM_1 * VRG_ORAN_5 VRG_ORAN_1 * VRG_ORAN_6 VRG_ORAN_1 * DMG_VRG_ORAN DMG_VRG_ORAN * YDIL_A_KSAYI YDIL_A_KSAYI * YDIL_B_KSAYI YDIL_B_KSAYI * YDIL_C_KSAYI YDIL_C_KSAYI * COCUK_KSAYI COCUK_KSAYI * EMEKLI_SAHIS_PAY EMEKLI_SAHIS_PAY * EMEKLI_KURUM_PAY EMEKLI_KURUM_PAY *----------------------------------------------------------------- 01 EZESTA-KATSAYI-GP. 02 EZESTA-ID PIC X(8) VALUE "ELAASGSR". 02 EZESTA-KATSAYI-LL PIC S9(8) COMP VALUE +211. 02 EZESTA-KATSAYI-RC PIC S9(2) VALUE 00. 88 EZESTA-KATSAYI-OK VALUE 00. 88 EZESTA-KATSAYI-ERR VALUES ARE -99 THRU -01 01 THRU 99. 88 EZESTA-KATSAYI-SFT VALUES ARE 01 THRU 99. 88 EZESTA-KATSAYI-DED VALUE -01. 88 EZESTA-KATSAYI-DUP VALUE -05. 88 EZESTA-KATSAYI-EOF VALUE 03 07. 88 EZESTA-KATSAYI-NRF VALUE 04 07. 88 EZESTA-KATSAYI-UNQ VALUE -05. 88 EZESTA-KATSAYI-HRD VALUES ARE -99 THRU -01. 88 EZESTA-KATSAYI-FUL VALUE -06. 88 EZESTA-KATSAYI-FNA VALUE -07. 88 EZESTA-KATSAYI-FMT VALUE -08. 88 EZESTA-KATSAYI-FNF VALUE -09. 88 EZESTA-KATSAYI-LOK VALUE -10. 02 FILLER PIC X(18) VALUE "KATSAYI". *----------------------------------------------------------------- * RECORD NAME : KATSAYI * FILE ORGANIZATION : SQLROW * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 14:54:09 * RECORD PROLOGUE : * *----------------------------------------------------------------- 02 KATSAYI. 10 FILLER PIC X(4). * DONEM_TARIH WAS RENAMED TO EZEI-1 10 EZEI-1 PIC X(10) USAGE DISPLAY. 10 FILLER PIC X(4). * MAAS_KSAYI WAS RENAMED TO EZEI-2 10 EZEI-2 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * TABAN_AY_KSAYI WAS RENAMED TO EZEI-3 10 EZEI-3 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * YAN_ODE_KSAYI WAS RENAMED TO EZEI-4 10 EZEI-4 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_1 WAS RENAMED TO EZEI-5 10 EZEI-5 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_1 WAS RENAMED TO EZEI-6 10 EZEI-6 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_1 WAS RENAMED TO EZEI-7 10 EZEI-7 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_1 WAS RENAMED TO EZEI-8 10 EZEI-8 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_1 WAS RENAMED TO EZEI-9 10 EZEI-9 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_1 WAS RENAMED TO EZEI-10 10 EZEI-10 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_1 WAS RENAMED TO EZEI-11 10 EZEI-11 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_1 WAS RENAMED TO EZEI-12 10 EZEI-12 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_1 WAS RENAMED TO EZEI-13 10 EZEI-13 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_1 WAS RENAMED TO EZEI-14 10 EZEI-14 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_ORAN_1 WAS RENAMED TO EZEI-15 10 EZEI-15 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * DMG_VRG_ORAN WAS RENAMED TO EZEI-16 10 EZEI-16 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * YDIL_A_KSAYI WAS RENAMED TO EZEI-17 10 EZEI-17 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * YDIL_B_KSAYI WAS RENAMED TO EZEI-18 10 EZEI-18 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * YDIL_C_KSAYI WAS RENAMED TO EZEI-19 10 EZEI-19 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * COCUK_KSAYI WAS RENAMED TO EZEI-20 10 EZEI-20 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * EMEKLI_SAHIS_PAY WAS RENAMED TO EZEI-21 10 EZEI-21 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * EMEKLI_KURUM_PAY WAS RENAMED TO EZEI-22 10 EZEI-22 PIC S9(9) USAGE COMP. 02 EZESQL-KATSAYI-H REDEFINES KATSAYI. 10 FILLER PIC X(4). 10 EZEI-1 PIC X(10) USAGE DISPLAY. 10 FILLER PIC X(4). 10 EZEI-2 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-3 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-4 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-5 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 EZEI-6 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-7 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 EZEI-8 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-9 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 EZEI-10 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-11 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 EZEI-12 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-13 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 EZEI-14 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-15 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-16 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-17 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-18 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-19 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-20 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-21 PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EZEI-22 PIC S9(9) USAGE COMP. 02 EZESQL-KATSAYI-I REDEFINES KATSAYI. 10 EZEI-1 PIC S9(4) COMP. 10 FILLER PIC X(12). 10 EZEI-2 PIC S9(4) COMP. 10 FILLER PIC X(6). 10 EZEI-3 PIC S9(4) COMP. 10 FILLER PIC X(6). 10 EZEI-4 PIC S9(4) COMP. 10 FILLER PIC X(6). 10 EZEI-5 PIC S9(4) COMP. 10 FILLER PIC X(9). 10 EZEI-6 PIC S9(4) COMP. 10 FILLER PIC X(4). 10 EZEI-7 PIC S9(4) COMP. 10 FILLER PIC X(9). 10 EZEI-8 PIC S9(4) COMP. 10 FILLER PIC X(4). 10 EZEI-9 PIC S9(4) COMP. 10 FILLER PIC X(9). 10 EZEI-10 PIC S9(4) COMP. 10 FILLER PIC X(4). 10 EZEI-11 PIC S9(4) COMP. 10 FILLER PIC X(9). 10 EZEI-12 PIC S9(4) COMP. 10 FILLER PIC X(4). 10 EZEI-13 PIC S9(4) COMP. 10 FILLER PIC X(9). 10 EZEI-14 PIC S9(4) COMP. 10 FILLER PIC X(4). 10 EZEI-15 PIC S9(4) COMP. 10 FILLER PIC X(4). 10 EZEI-16 PIC S9(4) COMP. 10 FILLER PIC X(4). 10 EZEI-17 PIC S9(4) COMP. 10 FILLER PIC X(6). 10 EZEI-18 PIC S9(4) COMP. 10 FILLER PIC X(6). 10 EZEI-19 PIC S9(4) COMP. 10 FILLER PIC X(6). 10 EZEI-20 PIC S9(4) COMP. 10 FILLER PIC X(6). 10 EZEI-21 PIC S9(4) COMP. 10 FILLER PIC X(6). 10 EZEI-22 PIC S9(4) COMP. 10 FILLER PIC X(6). 02 FILLER PIC X(4) VALUE "*END". LINKAGE SECTION. 01 DFHCOMMAREA. 05 EZECOMMAREA PIC X(32763). 05 EZECOMMAREA-MAPPED REDEFINES EZECOMMAREA. 10 EZECOMMAREA-SSM-STATUS PIC X. 10 EZECOMMAREA-MAP-NAME PIC X(8). 10 EZECOMMAREA-RESERVED-0 PIC X. 10 EZECOMMAREA-USER-AREA PIC X(32753). 05 EZECOMMAREA-POINTERS REDEFINES EZECOMMAREA. 10 EZECOMMAREA-PTR USAGE IS POINTER OCCURS 8190 TIMES. 10 EZECOMMAREA-PTR-RSVD PIC X(3). * RTS CONTROL BLOCK COPY ELARHRTS REPLACING ==SYNCHRONIZED EXTERNAL== BY ==SYNCHRONIZED==. * RTS NLS-DEPENDENT INSTALLATION OPTIONS CONTROL BLOCK COPY ELARHIOE. * RTS NLS-INDEPENDENT INSTALLATION OPTIONS CONTROL BLOCK COPY ELARHIOP. * RESOURCE CONTROL BLOCK COPY ELARHRSC. * STATIC CONTROL BLOCK COPY ELARHSCB. *----------------------------------------------------------------- * RECORD NAME : WKATSAYI * FILE ORGANIZATION : SQLROW * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 15:55:08 * RECORD PROLOGUE : * *----------------------------------------------------------------- 01 EZERCD-WKATSAYI-GP. 02 WKATSAYI. 10 FILLER PIC X(4). * DONEM_TARIH WAS RENAMED TO DONEM-TARIH 10 DONEM-TARIH PIC X(10) USAGE DISPLAY. 10 FILLER PIC X(4). * MAAS_KSAYI WAS RENAMED TO MAAS-KSAYI 10 MAAS-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * TABAN_AY_KSAYI WAS RENAMED TO TABAN-AY-KSAYI 10 TABAN-AY-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * YAN_ODE_KSAYI WAS RENAMED TO YAN-ODE-KSAYI 10 YAN-ODE-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_1 WAS RENAMED TO VRG-DILIM-1 10 VRG-DILIM-1 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_1 WAS RENAMED TO VRG-ORAN-1 10 VRG-ORAN-1 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_2 WAS RENAMED TO VRG-DILIM-2 10 VRG-DILIM-2 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_2 WAS RENAMED TO VRG-ORAN-2 10 VRG-ORAN-2 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_3 WAS RENAMED TO VRG-DILIM-3 10 VRG-DILIM-3 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_3 WAS RENAMED TO VRG-ORAN-3 10 VRG-ORAN-3 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_4 WAS RENAMED TO VRG-DILIM-4 10 VRG-DILIM-4 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_4 WAS RENAMED TO VRG-ORAN-4 10 VRG-ORAN-4 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_DILIM_5 WAS RENAMED TO VRG-DILIM-5 10 VRG-DILIM-5 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). * VRG_ORAN_5 WAS RENAMED TO VRG-ORAN-5 10 VRG-ORAN-5 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * VRG_ORAN_6 WAS RENAMED TO VRG-ORAN-6 10 VRG-ORAN-6 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * DMG_VRG_ORAN WAS RENAMED TO DMG-VRG-ORAN 10 DMG-VRG-ORAN PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). * YDIL_A_KSAYI WAS RENAMED TO YDIL-A-KSAYI 10 YDIL-A-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * YDIL_B_KSAYI WAS RENAMED TO YDIL-B-KSAYI 10 YDIL-B-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * YDIL_C_KSAYI WAS RENAMED TO YDIL-C-KSAYI 10 YDIL-C-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * COCUK_KSAYI WAS RENAMED TO COCUK-KSAYI 10 COCUK-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * EMEKLI_SAHIS_PAY WAS RENAMED TO EMEKLI-SAHIS-PAY 10 EMEKLI-SAHIS-PAY PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). * EMEKLI_KURUM_PAY WAS RENAMED TO EMEKLI-KURUM-PAY 10 EMEKLI-KURUM-PAY PIC S9(9) USAGE COMP. 01 EZESQL-WKATSAYI-H REDEFINES EZERCD-WKATSAYI-GP. 10 FILLER PIC X(4). 10 DONEM-TARIH PIC X(10) USAGE DISPLAY. 10 FILLER PIC X(4). 10 MAAS-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 TABAN-AY-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 YAN-ODE-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 VRG-DILIM-1 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 VRG-ORAN-1 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 VRG-DILIM-2 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 VRG-ORAN-2 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 VRG-DILIM-3 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 VRG-ORAN-3 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 VRG-DILIM-4 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 VRG-ORAN-4 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 VRG-DILIM-5 PIC S9(13) USAGE COMP-3. 10 FILLER PIC X(4). 10 VRG-ORAN-5 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 VRG-ORAN-6 PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 DMG-VRG-ORAN PIC S9(4) USAGE COMP. 10 FILLER PIC X(4). 10 YDIL-A-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 YDIL-B-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 YDIL-C-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 COCUK-KSAYI PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EMEKLI-SAHIS-PAY PIC S9(9) USAGE COMP. 10 FILLER PIC X(4). 10 EMEKLI-KURUM-PAY PIC S9(9) USAGE COMP. 01 EZESQL-WKATSAYI-I REDEFINES EZERCD-WKATSAYI-GP. 10 DONEM-TARIH PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC X(10) USAGE DISPLAY. 10 MAAS-KSAYI PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(9) USAGE COMP. 10 TABAN-AY-KSAYI PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(9) USAGE COMP. 10 YAN-ODE-KSAYI PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(9) USAGE COMP. 10 VRG-DILIM-1 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(13) USAGE COMP-3. 10 VRG-ORAN-1 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(4) USAGE COMP. 10 VRG-DILIM-2 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(13) USAGE COMP-3. 10 VRG-ORAN-2 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(4) USAGE COMP. 10 VRG-DILIM-3 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(13) USAGE COMP-3. 10 VRG-ORAN-3 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(4) USAGE COMP. 10 VRG-DILIM-4 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(13) USAGE COMP-3. 10 VRG-ORAN-4 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(4) USAGE COMP. 10 VRG-DILIM-5 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(13) USAGE COMP-3. 10 VRG-ORAN-5 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(4) USAGE COMP. 10 VRG-ORAN-6 PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(4) USAGE COMP. 10 DMG-VRG-ORAN PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(4) USAGE COMP. 10 YDIL-A-KSAYI PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(9) USAGE COMP. 10 YDIL-B-KSAYI PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(9) USAGE COMP. 10 YDIL-C-KSAYI PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(9) USAGE COMP. 10 COCUK-KSAYI PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(9) USAGE COMP. 10 EMEKLI-SAHIS-PAY PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(9) USAGE COMP. 10 EMEKLI-KURUM-PAY PIC S9(4) COMP. 10 FILLER PIC X(2). 10 FILLER PIC S9(9) USAGE COMP. *----------------------------------------------------------------- * RECORD NAME : VDBCONTROL * FILE ORGANIZATION : WORKSTOR * MODIFICATION DATE : 01.06.2000 * MODIFICATION TIME : 10:49:21 * RECORD PROLOGUE : * ************************************************************ * * Record : VDBCONTROL * * * * Function : Database and control information to pass * * between umbrella and atomic server * * applications. * * ************************************************************ *----------------------------------------------------------------- 01 EZERCD-VDBCONTROL-GP. 02 VDBCONTROL. * Database Control Record Item 05 UDBCONTROL PIC X(74) USAGE DISPLAY. 05 EZE-REDEF-4 REDEFINES UDBCONTROL. * Return Code (CHA) 06 URCCHAR PIC X(3) USAGE DISPLAY. 06 EZE-REDEF-5 REDEFINES URCCHAR. * Return Code 07 URC PIC S9(3) USAGE DISPLAY. * Rollback Required Flag 06 UROLLBACK PIC X(1) USAGE DISPLAY. * Error Message Inserts from SQL 06 UEZESQRRM PIC X(70) USAGE DISPLAY. * Database Local Area 05 UDBLOCAL PIC X(11) USAGE DISPLAY. 05 EZE-REDEF-6 REDEFINES UDBLOCAL. * SQL Access Type 06 UACCTYP PIC X(1) USAGE DISPLAY. * Access Type Save 06 UACCSAV PIC X(1) USAGE DISPLAY. * Rows Read Counter 06 UROWR PIC S9(9) USAGE COMP. * Rows Written Counter 06 UROWW PIC S9(9) USAGE COMP. * Req. I/O (ISUD) or List (LFB) 06 UIOTYPE PIC X(1) USAGE DISPLAY. * NRF Flag 05 UNRF PIC X(1) USAGE DISPLAY. * HIGH-VALUE WAS RENAMED TO EZEI-HIGH-VALUE 05 EZEI-HIGH-VALUE PIC X(1) USAGE DISPLAY. 05 EZE-REDEF-7 REDEFINES EZEI-HIGH-VALUE. 06 HIGH-VALUE-HEX PIC X(1) USAGE DISPLAY. * LOW-VALUE WAS RENAMED TO EZEI-LOW-VALUE 05 EZEI-LOW-VALUE PIC X(1) USAGE DISPLAY. 05 EZE-REDEF-8 REDEFINES EZEI-LOW-VALUE. 06 LOW-VALUE-HEX PIC X(1) USAGE DISPLAY. * HIGH-VALUES WAS RENAMED TO EZEI-HIGH-VALUES 05 EZEI-HIGH-VALUES PIC X(100) USAGE DISPLAY. 05 EZE-REDEF-9 REDEFINES EZEI-HIGH-VALUES. 06 HIGH-VALUES-CHAR PIC X(1) OCCURS 100 INDEXED BY EZEIDX1 USAGE DISPLAY. * LOW-VALUES WAS RENAMED TO EZEI-LOW-VALUES 05 EZEI-LOW-VALUES PIC X(100) USAGE DISPLAY. 05 EZE-REDEF-10 REDEFINES EZEI-LOW-VALUES. 06 LOW-VALUES-CHAR PIC X(1) OCCURS 100 INDEXED BY EZEIDX2 USAGE DISPLAY. *----------------------------------------------------------------- * RECORD NAME : VMESSAGE * FILE ORGANIZATION : WORKSTOR * MODIFICATION DATE : 01.06.2000 * MODIFICATION TIME : 10:49:43 * RECORD PROLOGUE : * ************************************************************ * * Record : VMESSAGE * * * * Function : Message record. * * * ************************************************************ *----------------------------------------------------------------- 01 EZERCD-VMESSAGE-GP. 02 VMESSAGE. 05 UMSGCONTROL PIC X(224) USAGE DISPLAY. 05 EZE-REDEF-11 REDEFINES UMSGCONTROL. * Message Code 06 UMSGCODE PIC X(8) USAGE DISPLAY. * Message Insert 06 UMSGINS PIC X(30) OCCURS 3 INDEXED BY EZEIDX3 USAGE DISPLAY. * Message Text 06 UMESSAGE PIC X(125) USAGE DISPLAY. * Message Type 06 UMSGTYPE PIC X(1) USAGE DISPLAY. EXEC SQL DECLARE EZE001001KGGSM1 CURSOR FOR SELECT MAAS_KSAYI , TABAN_AY_KSAYI , YAN_ODE_KSAYI , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_ORAN_1 , DMG_VRG_ORAN , YDIL_A_KSAYI , YDIL_B_KSAYI , YDIL_C_KSAYI , COCUK_KSAYI , EMEKLI_SAHIS_PAY , EMEKLI_KURUM_PAY FROM BORDRO.KATSAYI T1 WHERE DONEM_TARIH = :EZESQL-KATSAYI-H.EZEI-1:EZESQL-KATSAYI-I.EZEI-1 FOR UPDATE OF MAAS_KSAYI , TABAN_AY_KSAYI , YAN_ODE_KSAYI , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_ORAN_1 , DMG_VRG_ORAN , YDIL_A_KSAYI , YDIL_B_KSAYI , YDIL_C_KSAYI , COCUK_KSAYI , EMEKLI_SAHIS_PAY , EMEKLI_KURUM_PAY END-EXEC. *----------------------------------------------------------------- * SQL CURSOR CONTROL BLOCKS *----------------------------------------------------------------- 01 EZECRS-CURSOR-BLOCKS. 02 EZECRS-ID PIC X(8). 02 EZECRS-CNT PIC S9(4) COMP. *----------------------------------------------------------------- * CURSOR CONTROL BLOCK FOR SQL ROW KATSAYI *----------------------------------------------------------------- 02 EZECRS-KATSAYI-CB. 05 EZECRS-KATSAYI-TYP PIC X(4). 88 EZECRS-KATSAYI-SETI VALUE "SETI". 88 EZECRS-KATSAYI-SETU VALUE "SETU". 88 EZECRS-KATSAYI-SIWH VALUE "SIWH". 88 EZECRS-KATSAYI-SUWH VALUE "SUWH". 88 EZECRS-KATSAYI-UPDT VALUE "UPDT". 88 EZECRS-KATSAYI-INQU VALUE "INQU". 05 EZECRS-KATSAYI-ID PIC S9(4) COMP. 88 EZECRS-KATSAYI-CLOS VALUE 0. PROCEDURE DIVISION. *----------------------------------------------------------------- * MAIN PROCESS *----------------------------------------------------------------- EZEMAIN-PROCESS SECTION. PERFORM EZECONTROL GOBACK. *----------------------------------------------------------------- * BEGIN PROCESS *----------------------------------------------------------------- EZEBEGIN-PROCESSES SECTION. CONTINUE. *----------------------------------------------------------------- * SQL PROCESS OPTIONS BYPASS *----------------------------------------------------------------- EZESQL-PROCESS-BYPASS SECTION. GO TO KGGSM1-MAIN. EZESQL-PROCESS-BYPASS-X. EXIT. *----------------------------------------------------------------- * SQL PROCESS OPTIONS * * SQL CLOSE CURSOR AND PROCESS OPTIONS SECTIONS ARE PLACED AT THE * TOP OF THE PROGRAM. * THE SQL PREPROCESSOR DOES NOT PROCESS EXEC SQL STATEMENTS AFTER * 32,767. *----------------------------------------------------------------- *----------------------------------------------------------------- * CLOSE CURSOR FOR SQL ROW KATSAYI *----------------------------------------------------------------- EZECLOSCU-KATSAYI SECTION. MOVE SPACES TO EZECRS-KATSAYI-TYP IF EZECRS-KATSAYI-CLOS GO TO EZECLOSCU-KATSAYI-X END-IF IF EZECRS-KATSAYI-ID = 1 EXEC SQL CLOSE EZE001001KGGSM1 END-EXEC END-IF SET EZECRS-KATSAYI-CLOS TO TRUE MOVE "CLOSE" TO EZERTS-SQL-COMMAND PERFORM EZESQL-ERROR-ROUTINE IF EZERTS-PRC-OPT = "CLOSE" OR (SQLCODE NOT = 0 AND EZESQCOD = 0) MOVE SQLCA TO EZESQLCA MOVE EZERTS-SQLERR-STATUS TO EZESTA-KATSAYI-RC END-IF. EZECLOSCU-KATSAYI-X. EXIT. *----------------------------------------------------------------- * INPUT / OUTPUT ROUTINE FOR PROCESS KATSAYI-DEL *----------------------------------------------------------------- * PROCESS OPTION : DELETE * PROCESS OBJECT : KATSAYI *----------------------------------------------------------------- EZEDELT-KATSAYI-DEL SECTION. MOVE "KATSAYI-DEL" TO EZERTS-PRC-NAME MOVE "DELETE" TO EZERTS-PRC-OPT MOVE "KATSAYI" TO EZERTS-PRC-OBJ SET EZERTS-NO-ERROR-ROUTINE TO TRUE MOVE ZEROES TO EZESTA-KATSAYI-RC IF EZECRS-KATSAYI-CLOS OR EZECRS-KATSAYI-SETI OR EZECRS-KATSAYI-SIWH MOVE 0086 TO EZERTS-ERROR-NUM CALL "ELARSVCS" USING EZERTS-CONTROL-BLOCK EZERTS-ERROR-REQUEST-BLOCK GO TO EZETERMINATE END-IF IF EZECRS-KATSAYI-ID = 1 EXEC SQL DELETE FROM BORDRO.KATSAYI WHERE CURRENT OF EZE001001KGGSM1 END-EXEC END-IF MOVE "DELETE" TO EZERTS-SQL-COMMAND PERFORM EZESQL-ERROR-ROUTINE MOVE EZERTS-SQLERR-STATUS TO EZESTA-KATSAYI-RC IF EZECRS-KATSAYI-UPDT PERFORM EZECLOSCU-KATSAYI END-IF. EZEDEL-KATSAYI-DEL-ERR. IF EZESTA-KATSAYI-ERR SET EZERTS-EZECLOS TO TRUE GO TO EZETERMINATE END-IF CONTINUE. EZEDELT-KATSAYI-DEL-X. EXIT. *----------------------------------------------------------------- * INPUT / OUTPUT ROUTINE FOR PROCESS KATSAYI_ADD *----------------------------------------------------------------- * PROCESS OPTION : ADD * PROCESS OBJECT : KATSAYI *----------------------------------------------------------------- EZEADD-KATSAYI-ADD SECTION. MOVE "KATSAYI_ADD" TO EZERTS-PRC-NAME MOVE "ADD" TO EZERTS-PRC-OPT MOVE "KATSAYI" TO EZERTS-PRC-OBJ SET EZERTS-NO-ERROR-ROUTINE TO TRUE MOVE ZEROES TO EZESTA-KATSAYI-RC EXEC SQL INSERT INTO BORDRO.KATSAYI (DONEM_TARIH , MAAS_KSAYI , TABAN_AY_KSAYI , YAN_ODE_KSAYI , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_DILIM_1 , VRG_ORAN_1 , VRG_ORAN_1 , DMG_VRG_ORAN , YDIL_A_KSAYI , YDIL_B_KSAYI , YDIL_C_KSAYI , COCUK_KSAYI , EMEKLI_SAHIS_PAY , EMEKLI_KURUM_PAY ) VALUES (:EZESQL-KATSAYI-H.EZEI-1:EZESQL-KATSAYI-I.EZEI-1 , :EZESQL-KATSAYI-H.EZEI-2:EZESQL-KATSAYI-I.EZEI-2 , :EZESQL-KATSAYI-H.EZEI-3:EZESQL-KATSAYI-I.EZEI-3 , :EZESQL-KATSAYI-H.EZEI-4:EZESQL-KATSAYI-I.EZEI-4 , :EZESQL-KATSAYI-H.EZEI-5:EZESQL-KATSAYI-I.EZEI-5 , :EZESQL-KATSAYI-H.EZEI-6:EZESQL-KATSAYI-I.EZEI-6 , :EZESQL-KATSAYI-H.EZEI-7:EZESQL-KATSAYI-I.EZEI-7 , :EZESQL-KATSAYI-H.EZEI-8:EZESQL-KATSAYI-I.EZEI-8 , :EZESQL-KATSAYI-H.EZEI-9:EZESQL-KATSAYI-I.EZEI-9 , :EZESQL-KATSAYI-H.EZEI-10:EZESQL-KATSAYI-I.EZEI-10 , :EZESQL-KATSAYI-H.EZEI-11:EZESQL-KATSAYI-I.EZEI-11 , :EZESQL-KATSAYI-H.EZEI-12:EZESQL-KATSAYI-I.EZEI-12 , :EZESQL-KATSAYI-H.EZEI-13:EZESQL-KATSAYI-I.EZEI-13 , :EZESQL-KATSAYI-H.EZEI-14:EZESQL-KATSAYI-I.EZEI-14 , :EZESQL-KATSAYI-H.EZEI-15:EZESQL-KATSAYI-I.EZEI-15 , :EZESQL-KATSAYI-H.EZEI-16:EZESQL-KATSAYI-I.EZEI-16 , :EZESQL-KATSAYI-H.EZEI-17:EZESQL-KATSAYI-I.EZEI-17 , :EZESQL-KATSAYI-H.EZEI-18:EZESQL-KATSAYI-I.EZEI-18 , :EZESQL-KATSAYI-H.EZEI-19:EZESQL-KATSAYI-I.EZEI-19 , :EZESQL-KATSAYI-H.EZEI-20:EZESQL-KATSAYI-I.EZEI-20 , :EZESQL-KATSAYI-H.EZEI-21:EZESQL-KATSAYI-I.EZEI-21 , :EZESQL-KATSAYI-H.EZEI-22:EZESQL-KATSAYI-I.EZEI-22 ) END-EXEC MOVE "INSERT" TO EZERTS-SQL-COMMAND PERFORM EZESQL-ERROR-ROUTINE MOVE EZERTS-SQLERR-STATUS TO EZESTA-KATSAYI-RC CONTINUE. EZEADD-KATSAYI-ADD-ERR. IF EZESTA-KATSAYI-ERR SET EZERTS-EZECLOS TO TRUE GO TO EZETERMINATE END-IF CONTINUE. EZEADD-KATSAYI-ADD-X. EXIT. *----------------------------------------------------------------- * INPUT / OUTPUT ROUTINE FOR PROCESS KATSAYI_REP1 *----------------------------------------------------------------- * PROCESS OPTION : REPLACE * PROCESS OBJECT : KATSAYI *----------------------------------------------------------------- EZEREPL-KATSAYI-REP1 SECTION. MOVE "KATSAYI_REP1" TO EZERTS-PRC-NAME MOVE "REPLACE" TO EZERTS-PRC-OPT MOVE "KATSAYI" TO EZERTS-PRC-OBJ SET EZERTS-NO-ERROR-ROUTINE TO TRUE MOVE ZEROES TO EZESTA-KATSAYI-RC IF EZECRS-KATSAYI-CLOS OR EZECRS-KATSAYI-SETI OR EZECRS-KATSAYI-SIWH MOVE 0086 TO EZERTS-ERROR-NUM CALL "ELARSVCS" USING EZERTS-CONTROL-BLOCK EZERTS-ERROR-REQUEST-BLOCK GO TO EZETERMINATE END-IF IF EZECRS-KATSAYI-ID = 1 EXEC SQL UPDATE BORDRO.KATSAYI SET MAAS_KSAYI = :EZESQL-KATSAYI-H.EZEI-2:EZESQL-KATSAYI-I.EZEI-2 , TABAN_AY_KSAYI = :EZESQL-KATSAYI-H.EZEI-3:EZESQL-KATSAYI-I.EZEI-3 , YAN_ODE_KSAYI = :EZESQL-KATSAYI-H.EZEI-4:EZESQL-KATSAYI-I.EZEI-4 , VRG_DILIM_1 = :EZESQL-KATSAYI-H.EZEI-5:EZESQL-KATSAYI-I.EZEI-5 , VRG_ORAN_1 = :EZESQL-KATSAYI-H.EZEI-6:EZESQL-KATSAYI-I.EZEI-6 , VRG_DILIM_1 = :EZESQL-KATSAYI-H.EZEI-7:EZESQL-KATSAYI-I.EZEI-7 , VRG_ORAN_1 = :EZESQL-KATSAYI-H.EZEI-8:EZESQL-KATSAYI-I.EZEI-8 , VRG_DILIM_1 = :EZESQL-KATSAYI-H.EZEI-9:EZESQL-KATSAYI-I.EZEI-9 , VRG_ORAN_1 = :EZESQL-KATSAYI-H.EZEI-10:EZESQL-KATSAYI-I.EZEI-10 , VRG_DILIM_1 = :EZESQL-KATSAYI-H.EZEI-11:EZESQL-KATSAYI-I.EZEI-11 , VRG_ORAN_1 = :EZESQL-KATSAYI-H.EZEI-12:EZESQL-KATSAYI-I.EZEI-12 , VRG_DILIM_1 = :EZESQL-KATSAYI-H.EZEI-13:EZESQL-KATSAYI-I.EZEI-13 , VRG_ORAN_1 = :EZESQL-KATSAYI-H.EZEI-14:EZESQL-KATSAYI-I.EZEI-14 , VRG_ORAN_1 = :EZESQL-KATSAYI-H.EZEI-15:EZESQL-KATSAYI-I.EZEI-15 , DMG_VRG_ORAN = :EZESQL-KATSAYI-H.EZEI-16:EZESQL-KATSAYI-I.EZEI-16 , YDIL_A_KSAYI = :EZESQL-KATSAYI-H.EZEI-17:EZESQL-KATSAYI-I.EZEI-17 , YDIL_B_KSAYI = :EZESQL-KATSAYI-H.EZEI-18:EZESQL-KATSAYI-I.EZEI-18 , YDIL_C_KSAYI = :EZESQL-KATSAYI-H.EZEI-19:EZESQL-KATSAYI-I.EZEI-19 , COCUK_KSAYI = :EZESQL-KATSAYI-H.EZEI-20:EZESQL-KATSAYI-I.EZEI-20 , EMEKLI_SAHIS_PAY = :EZESQL-KATSAYI-H.EZEI-21:EZESQL-KATSAYI-I.EZEI-21 , EMEKLI_KURUM_PAY = :EZESQL-KATSAYI-H.EZEI-22:EZESQL-KATSAYI-I.EZEI-22 WHERE CURRENT OF EZE001001KGGSM1 END-EXEC END-IF MOVE "UPDATE" TO EZERTS-SQL-COMMAND PERFORM EZESQL-ERROR-ROUTINE MOVE EZERTS-SQLERR-STATUS TO EZESTA-KATSAYI-RC IF EZECRS-KATSAYI-UPDT PERFORM EZECLOSCU-KATSAYI END-IF. EZEREPL-KATSAYI-REP1-ERR. IF EZESTA-KATSAYI-ERR SET EZERTS-EZECLOS TO TRUE GO TO EZETERMINATE END-IF CONTINUE. EZEREPL-KATSAYI-REP1-X. EXIT. *----------------------------------------------------------------- * INPUT / OUTPUT ROUTINE FOR PROCESS KATSAYI_UPD1 *----------------------------------------------------------------- * PROCESS OPTION : UPDATE * PROCESS OBJECT : KATSAYI *----------------------------------------------------------------- EZEUPDT-KATSAYI-UPD1 SECTION. MOVE "KATSAYI_UPD1" TO EZERTS-PRC-NAME MOVE "UPDATE" TO EZERTS-PRC-OPT MOVE "KATSAYI" TO EZERTS-PRC-OBJ SET EZERTS-NO-ERROR-ROUTINE TO TRUE MOVE ZEROES TO EZESTA-KATSAYI-RC IF NOT EZECRS-KATSAYI-CLOS PERFORM EZECLOSCU-KATSAYI IF EZESTA-KATSAYI-HRD GO TO EZEUPD-KATSAYI-UPD1-ERR END-IF END-IF EXEC SQL OPEN EZE001001KGGSM1 END-EXEC MOVE "OPEN" TO EZERTS-SQL-COMMAND PERFORM EZESQL-ERROR-ROUTINE MOVE EZERTS-SQLERR-STATUS TO EZESTA-KATSAYI-RC IF EZESTA-KATSAYI-HRD OR EZESTA-KATSAYI-NRF GO TO EZEUPD-KATSAYI-UPD1-ERR END-IF MOVE 1 TO EZECRS-KATSAYI-ID MOVE "UPDT" TO EZECRS-KATSAYI-TYP EXEC SQL FETCH EZE001001KGGSM1 INTO :EZESQL-KATSAYI-H.EZEI-2:EZESQL-KATSAYI-I.EZEI-2 , :EZESQL-KATSAYI-H.EZEI-3:EZESQL-KATSAYI-I.EZEI-3 , :EZESQL-KATSAYI-H.EZEI-4:EZESQL-KATSAYI-I.EZEI-4 , :EZESQL-KATSAYI-H.EZEI-5:EZESQL-KATSAYI-I.EZEI-5 , :EZESQL-KATSAYI-H.EZEI-6:EZESQL-KATSAYI-I.EZEI-6 , :EZESQL-KATSAYI-H.EZEI-7:EZESQL-KATSAYI-I.EZEI-7 , :EZESQL-KATSAYI-H.EZEI-8:EZESQL-KATSAYI-I.EZEI-8 , :EZESQL-KATSAYI-H.EZEI-9:EZESQL-KATSAYI-I.EZEI-9 , :EZESQL-KATSAYI-H.EZEI-10:EZESQL-KATSAYI-I.EZEI-10 , :EZESQL-KATSAYI-H.EZEI-11:EZESQL-KATSAYI-I.EZEI-11 , :EZESQL-KATSAYI-H.EZEI-12:EZESQL-KATSAYI-I.EZEI-12 , :EZESQL-KATSAYI-H.EZEI-13:EZESQL-KATSAYI-I.EZEI-13 , :EZESQL-KATSAYI-H.EZEI-14:EZESQL-KATSAYI-I.EZEI-14 , :EZESQL-KATSAYI-H.EZEI-15:EZESQL-KATSAYI-I.EZEI-15 , :EZESQL-KATSAYI-H.EZEI-16:EZESQL-KATSAYI-I.EZEI-16 , :EZESQL-KATSAYI-H.EZEI-17:EZESQL-KATSAYI-I.EZEI-17 , :EZESQL-KATSAYI-H.EZEI-18:EZESQL-KATSAYI-I.EZEI-18 , :EZESQL-KATSAYI-H.EZEI-19:EZESQL-KATSAYI-I.EZEI-19 , :EZESQL-KATSAYI-H.EZEI-20:EZESQL-KATSAYI-I.EZEI-20 , :EZESQL-KATSAYI-H.EZEI-21:EZESQL-KATSAYI-I.EZEI-21 , :EZESQL-KATSAYI-H.EZEI-22:EZESQL-KATSAYI-I.EZEI-22 END-EXEC MOVE "FETCH" TO EZERTS-SQL-COMMAND PERFORM EZESQL-ERROR-ROUTINE MOVE EZERTS-SQLERR-STATUS TO EZESTA-KATSAYI-RC IF EZESTA-KATSAYI-HRD OR EZESTA-KATSAYI-NRF PERFORM EZECLOSCU-KATSAYI GO TO EZEUPD-KATSAYI-UPD1-ERR END-IF IF EZEI-2 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-2 OF KATSAYI END-IF IF EZEI-3 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-3 OF KATSAYI END-IF IF EZEI-4 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-4 OF KATSAYI END-IF IF EZEI-5 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-5 OF KATSAYI END-IF IF EZEI-6 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-6 OF KATSAYI END-IF IF EZEI-7 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-7 OF KATSAYI END-IF IF EZEI-8 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-8 OF KATSAYI END-IF IF EZEI-9 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-9 OF KATSAYI END-IF IF EZEI-10 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-10 OF KATSAYI END-IF IF EZEI-11 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-11 OF KATSAYI END-IF IF EZEI-12 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-12 OF KATSAYI END-IF IF EZEI-13 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-13 OF KATSAYI END-IF IF EZEI-14 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-14 OF KATSAYI END-IF IF EZEI-15 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-15 OF KATSAYI END-IF IF EZEI-16 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-16 OF KATSAYI END-IF IF EZEI-17 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-17 OF KATSAYI END-IF IF EZEI-18 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-18 OF KATSAYI END-IF IF EZEI-19 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-19 OF KATSAYI END-IF IF EZEI-20 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-20 OF KATSAYI END-IF IF EZEI-21 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-21 OF KATSAYI END-IF IF EZEI-22 OF EZESQL-KATSAYI-I NEGATIVE MOVE ZERO TO EZEI-22 OF KATSAYI END-IF CONTINUE. EZEUPD-KATSAYI-UPD1-ERR. IF EZESTA-KATSAYI-ERR SET EZERTS-EZECLOS TO TRUE GO TO EZETERMINATE END-IF CONTINUE. EZEUPDT-KATSAYI-UPD1-X. EXIT. *----------------------------------------------------------------- * MAIN PROCESS : KGGSM1-MAIN * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:40:52 * PROCESS OPTION : EXECUTE *----------------------------------------------------------------- KGGSM1-MAIN SECTION. MOVE "KGGSM1-MAIN" TO EZERTS-PRC-NAME 000001* /* Standard initialization for atomic database operations. 000002* PERFORM SQL-INIT; PERFORM EZEP-SQL-INIT 000003* 000004* /* Initialize Access Type (R=read, W=write). 000005* VDBCONTROL.UACCTYP = 'W'; MOVE "W" TO UACCTYP OF VDBCONTROL 000006* 000007* /* Store application name 000008* VDBCOMMON.UAPPLNAM = 'KGGSM1'; MOVE "KGGSM1" TO UAPPLNAM OF VDBCOMMON 000009* 000010* /* Store the name of the SQL record in the server common record. 000011* VDBCOMMON.USQLREC = 'KATSAYI'; MOVE "KATSAYI" TO USQLREC OF VDBCOMMON 000012* VDBCOMMON.UTABLNAM = "KATSAYI Bilgileri"; MOVE "KATSAYI Bilgileri" TO UTABLNAM OF VDBCOMMON 000013* 000014* /* Check if record already exists. 000015* KATSAYI.DONEM_TARIH = WKATSAYI.DONEM_TARIH; MOVE DONEM-TARIH OF EZESQL-WKATSAYI-I TO EZEI-1 OF EZESQL-KATSAYI-I MOVE DONEM-TARIH OF WKATSAYI TO EZEI-1 OF KATSAYI 000016* PERFORM KATSAYI_UPD1; PERFORM KATSAYI-UPD1 000017* /* If record does not exist. 000018* IF KATSAYI IS NRF; IF EZESTA-KATSAYI-NRF GO TO EZECONDLBL-1 END-IF GO TO EZECONDLBL-2 CONTINUE. EZECONDLBL-1. 000019* /* Insert new record in table 000020* IF VDBCONTROL.UIOTYPE EQ "I"; IF UIOTYPE OF VDBCONTROL = "I" GO TO EZECONDLBL-3 END-IF GO TO EZECONDLBL-4 CONTINUE. EZECONDLBL-3. 000021* PERFORM KGGSM1-INSERT; PERFORM KGGSM1-INSERT CONTINUE. EZECONDLBL-4. 000022* END; 000023* ELSE; /* Record does exist. GO TO EZECONDLBL-5 CONTINUE. EZECONDLBL-2. 000024* IF KATSAYI NOT ERR; IF NOT EZESTA-KATSAYI-ERR GO TO EZECONDLBL-6 END-IF GO TO EZECONDLBL-7 CONTINUE. EZECONDLBL-6. 000025* IF VDBCONTROL.UIOTYPE NE "I"; IF UIOTYPE OF VDBCONTROL NOT = "I" GO TO EZECONDLBL-8 END-IF GO TO EZECONDLBL-9 CONTINUE. EZECONDLBL-8. 000026* 000027* /* Update record in table 000028* IF VDBCONTROL.UIOTYPE EQ "U"; IF UIOTYPE OF VDBCONTROL = "U" GO TO EZECONDLBL-10 END-IF GO TO EZECONDLBL-11 CONTINUE. EZECONDLBL-10. 000029* /* Replace the record in the table 000030* PERFORM KGGSM1-REPLACE; PERFORM KGGSM1-REPLACE 000031* ELSE; GO TO EZECONDLBL-12 CONTINUE. EZECONDLBL-11. 000032* /* Delete record from table 000033* IF VDBCONTROL.UIOTYPE EQ "D"; IF UIOTYPE OF VDBCONTROL = "D" GO TO EZECONDLBL-13 END-IF GO TO EZECONDLBL-14 CONTINUE. EZECONDLBL-13. 000034* /* Remove data from table 000035* PERFORM KGGSM1-DELETE; PERFORM KGGSM1-DELETE CONTINUE. EZECONDLBL-14. 000036* END; CONTINUE. EZECONDLBL-12. 000037* END; 000038* ELSE; /* Record exists: duplicate key 000038* error GO TO EZECONDLBL-15 CONTINUE. EZECONDLBL-9. 000039* VMESSAGE.UMSGCODE = 'SQL0803'; MOVE "SQL0803" TO UMSGCODE OF VMESSAGE 000040* VDBCONTROL.URC = 1; MOVE 1 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) CONTINUE. EZECONDLBL-15. 000041* END; CONTINUE. EZECONDLBL-7. 000042* END; CONTINUE. EZECONDLBL-5. 000043* END; 000044* 000045* /* Standard error handling for atomic database operations. 000046* PERFORM SQL-ERROR; PERFORM EZEP-SQL-ERROR CONTINUE. EZE-KGGSM1-MAIN-X. EXIT. *----------------------------------------------------------------- * STRUCTURE LIST POST-PROCESSING *----------------------------------------------------------------- EZESTRUCTURE-FALLTHRU SECTION. GO TO EZETERMINATE. EZESTRUCTURE-FALLTHRU-X. EXIT. *----------------------------------------------------------------- * PROCESS : KATSAYI-DEL * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:40:47 * PROCESS OPTION : DELETE * PROCESS OBJECT : KATSAYI *----------------------------------------------------------------- KATSAYI-DEL SECTION. MOVE "KATSAYI-DEL" TO EZERTS-PRC-NAME PERFORM EZEDELT-KATSAYI-DEL CONTINUE. EZE-KATSAYI-DEL-X. EXIT. *----------------------------------------------------------------- * PROCESS : KATSAYI_ADD * : KATSAYI_ADD RENAMED TO KATSAYI-ADD * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:34:45 * PROCESS OPTION : ADD * PROCESS OBJECT : KATSAYI *----------------------------------------------------------------- KATSAYI-ADD SECTION. MOVE "KATSAYI_ADD" TO EZERTS-PRC-NAME PERFORM EZEADD-KATSAYI-ADD CONTINUE. EZE-KATSAYI-ADD-X. EXIT. *----------------------------------------------------------------- * PROCESS : KATSAYI_REP1 * : KATSAYI_REP1 RENAMED TO KATSAYI-REP1 * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:39:48 * PROCESS OPTION : REPLACE * PROCESS OBJECT : KATSAYI *----------------------------------------------------------------- KATSAYI-REP1 SECTION. MOVE "KATSAYI_REP1" TO EZERTS-PRC-NAME PERFORM EZEREPL-KATSAYI-REP1 CONTINUE. EZE-KATSAYI-REP1-X. EXIT. *----------------------------------------------------------------- * PROCESS : KATSAYI_UPD1 * : KATSAYI_UPD1 RENAMED TO KATSAYI-UPD1 * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:33:21 * PROCESS OPTION : UPDATE * PROCESS OBJECT : KATSAYI *----------------------------------------------------------------- KATSAYI-UPD1 SECTION. MOVE "KATSAYI_UPD1" TO EZERTS-PRC-NAME PERFORM EZEUPDT-KATSAYI-UPD1 CONTINUE. EZE-KATSAYI-UPD1-X. EXIT. *----------------------------------------------------------------- * PROCESS : KGGSM1-DELETE * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:40:49 * PROCESS OPTION : EXECUTE *----------------------------------------------------------------- KGGSM1-DELETE SECTION. MOVE "KGGSM1-DELETE" TO EZERTS-PRC-NAME 000059* /* Call process to delete row from table. 000060* PERFORM KATSAYI-DEL; PERFORM KATSAYI-DEL 000061* 000062* /* Set error flags. 000063* /* UNRF - no record found flag (Y,N,1) 000064* /* UDUP - duplicate key flag (Y,N) 000065* VDBCOMMON.UNRF = 'Y'; MOVE "Y" TO UNRF OF VDBCOMMON 000066* VDBCOMMON.UDUP = 'N'; MOVE "N" TO UDUP OF VDBCOMMON CONTINUE. EZE-KGGSM1-DELETE-X. EXIT. *----------------------------------------------------------------- * PROCESS : KGGSM1-INSERT * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:34:47 * PROCESS OPTION : EXECUTE *----------------------------------------------------------------- KGGSM1-INSERT SECTION. MOVE "KGGSM1-INSERT" TO EZERTS-PRC-NAME 000067* PERFORM KGGSM1-MOVEDATA; PERFORM KGGSM1-MOVEDATA 000068* /* Set error flags. 000069* /* UNRF - no record found flag (Y,N,1) 000070* /* UDUP - duplicate key flag (Y,N) 000071* VDBCOMMON.UNRF = 'N'; MOVE "N" TO UNRF OF VDBCOMMON 000072* VDBCOMMON.UDUP = 'Y'; MOVE "Y" TO UDUP OF VDBCOMMON 000073* PERFORM KATSAYI_ADD; PERFORM KATSAYI-ADD CONTINUE. EZE-KGGSM1-INSERT-X. EXIT. *----------------------------------------------------------------- * PROCESS : KGGSM1-MOVEDATA * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:34:15 * PROCESS OPTION : EXECUTE *----------------------------------------------------------------- KGGSM1-MOVEDATA SECTION. MOVE "KGGSM1-MOVEDATA" TO EZERTS-PRC-NAME 000074* KATSAYI = WKATSAYI; MOVE DONEM-TARIH OF EZESQL-WKATSAYI-I TO EZEI-1 OF EZESQL-KATSAYI-I MOVE DONEM-TARIH OF WKATSAYI TO EZEI-1 OF KATSAYI MOVE MAAS-KSAYI OF EZESQL-WKATSAYI-I TO EZEI-2 OF EZESQL-KATSAYI-I MOVE MAAS-KSAYI OF WKATSAYI TO EZEI-2 OF KATSAYI MOVE TABAN-AY-KSAYI OF EZESQL-WKATSAYI-I TO EZEI-3 OF EZESQL-KATSAYI-I MOVE TABAN-AY-KSAYI OF WKATSAYI TO EZEI-3 OF KATSAYI MOVE YAN-ODE-KSAYI OF EZESQL-WKATSAYI-I TO EZEI-4 OF EZESQL-KATSAYI-I MOVE YAN-ODE-KSAYI OF WKATSAYI TO EZEI-4 OF KATSAYI MOVE VRG-DILIM-1 OF EZESQL-WKATSAYI-I TO EZEI-5 OF EZESQL-KATSAYI-I MOVE VRG-DILIM-1 OF WKATSAYI TO EZEI-5 OF KATSAYI MOVE VRG-ORAN-1 OF EZESQL-WKATSAYI-I TO EZEI-6 OF EZESQL-KATSAYI-I MOVE VRG-ORAN-1 OF WKATSAYI TO EZEI-6 OF KATSAYI MOVE VRG-DILIM-2 OF EZESQL-WKATSAYI-I TO EZEI-7 OF EZESQL-KATSAYI-I MOVE VRG-DILIM-2 OF WKATSAYI TO EZEI-7 OF KATSAYI MOVE VRG-ORAN-2 OF EZESQL-WKATSAYI-I TO EZEI-8 OF EZESQL-KATSAYI-I MOVE VRG-ORAN-2 OF WKATSAYI TO EZEI-8 OF KATSAYI MOVE VRG-DILIM-3 OF EZESQL-WKATSAYI-I TO EZEI-9 OF EZESQL-KATSAYI-I MOVE VRG-DILIM-3 OF WKATSAYI TO EZEI-9 OF KATSAYI MOVE VRG-ORAN-3 OF EZESQL-WKATSAYI-I TO EZEI-10 OF EZESQL-KATSAYI-I MOVE VRG-ORAN-3 OF WKATSAYI TO EZEI-10 OF KATSAYI MOVE VRG-DILIM-4 OF EZESQL-WKATSAYI-I TO EZEI-11 OF EZESQL-KATSAYI-I MOVE VRG-DILIM-4 OF WKATSAYI TO EZEI-11 OF KATSAYI MOVE VRG-ORAN-4 OF EZESQL-WKATSAYI-I TO EZEI-12 OF EZESQL-KATSAYI-I MOVE VRG-ORAN-4 OF WKATSAYI TO EZEI-12 OF KATSAYI MOVE VRG-DILIM-5 OF EZESQL-WKATSAYI-I TO EZEI-13 OF EZESQL-KATSAYI-I MOVE VRG-DILIM-5 OF WKATSAYI TO EZEI-13 OF KATSAYI MOVE VRG-ORAN-5 OF EZESQL-WKATSAYI-I TO EZEI-14 OF EZESQL-KATSAYI-I MOVE VRG-ORAN-5 OF WKATSAYI TO EZEI-14 OF KATSAYI MOVE VRG-ORAN-6 OF EZESQL-WKATSAYI-I TO EZEI-15 OF EZESQL-KATSAYI-I MOVE VRG-ORAN-6 OF WKATSAYI TO EZEI-15 OF KATSAYI MOVE DMG-VRG-ORAN OF EZESQL-WKATSAYI-I TO EZEI-16 OF EZESQL-KATSAYI-I MOVE DMG-VRG-ORAN OF WKATSAYI TO EZEI-16 OF KATSAYI MOVE YDIL-A-KSAYI OF EZESQL-WKATSAYI-I TO EZEI-17 OF EZESQL-KATSAYI-I MOVE YDIL-A-KSAYI OF WKATSAYI TO EZEI-17 OF KATSAYI MOVE YDIL-B-KSAYI OF EZESQL-WKATSAYI-I TO EZEI-18 OF EZESQL-KATSAYI-I MOVE YDIL-B-KSAYI OF WKATSAYI TO EZEI-18 OF KATSAYI MOVE YDIL-C-KSAYI OF EZESQL-WKATSAYI-I TO EZEI-19 OF EZESQL-KATSAYI-I MOVE YDIL-C-KSAYI OF WKATSAYI TO EZEI-19 OF KATSAYI MOVE COCUK-KSAYI OF EZESQL-WKATSAYI-I TO EZEI-20 OF EZESQL-KATSAYI-I MOVE COCUK-KSAYI OF WKATSAYI TO EZEI-20 OF KATSAYI MOVE EMEKLI-SAHIS-PAY OF EZESQL-WKATSAYI-I TO EZEI-21 OF EZESQL-KATSAYI-I MOVE EMEKLI-SAHIS-PAY OF WKATSAYI TO EZEI-21 OF KATSAYI MOVE EMEKLI-KURUM-PAY OF EZESQL-WKATSAYI-I TO EZEI-22 OF EZESQL-KATSAYI-I MOVE EMEKLI-KURUM-PAY OF WKATSAYI TO EZEI-22 OF KATSAYI CONTINUE. EZE-KGGSM1-MOVEDATA-X. EXIT. *----------------------------------------------------------------- * PROCESS : KGGSM1-REPLACE * MODIFICATION DATE : 02.06.2000 * MODIFICATION TIME : 16:39:52 * PROCESS OPTION : EXECUTE *----------------------------------------------------------------- KGGSM1-REPLACE SECTION. MOVE "KGGSM1-REPLACE" TO EZERTS-PRC-NAME 000075* /* Copy the data to the SQL record 000076* PERFORM KGGSM1-MOVEDATA; PERFORM KGGSM1-MOVEDATA 000077* /* Replace the row in the table 000078* PERFORM KATSAYI_REP1; PERFORM KATSAYI-REP1 000079* 000080* /* Set error flags. 000081* /* UNRF - no record found vlag (Y,N,1) 000082* /* UDUP - duplicate key vlag (Y,N) 000083* VDBCOMMON.UNRF = 'N'; MOVE "N" TO UNRF OF VDBCOMMON 000084* VDBCOMMON.UDUP = 'Y'; MOVE "Y" TO UDUP OF VDBCOMMON CONTINUE. EZE-KGGSM1-REPLACE-X. EXIT. *----------------------------------------------------------------- * PROCESS : SQL-ERROR * : SQL-ERROR RENAMED TO EZEP-SQL-ERROR * MODIFICATION DATE : 01.06.2000 * MODIFICATION TIME : 10:43:35 * PROCESS OPTION : EXECUTE * DESCRIPTION : std. SQL error handler *----------------------------------------------------------------- EZEP-SQL-ERROR SECTION. MOVE "SQL-ERROR" TO EZERTS-PRC-NAME 000085* /* *********************************************************** 000086* /* * Process : SQL-ERROR 000087* /* * 000088* /* * Function : Reusable standard SQL error handling process. 000089* /* * 000090* /* ************************************************************ 000091* /* ----------------------------------------------------------- 000092* /* This process handles SQL errors. Depending on the values 000093* /* in EZESQLCOD, VDBCONTROL.URC and the UNRF and UDUP flags, 000094* /* the need of a ROLLBACK is required. 000095* /* 000096* /* ROLLBACK in only necessary when action type is 000097* /* UACCTYP = 'W'. Both COMMIT and ROLLBACK will have to 000098* /* be issued from the calling application (umbrella). 000099* /* 000100* /* Condition UNRF UDUP URC Commit or Rollback 000101* /* ========= ==== ==== === ================== 000102* /* EZESQCOD=0 * * 0 COMMIT 000103* /* EZESQCOD=100 Y * 100 ROLLBACK 000104* /* EZESQCOD=100 N * 0 COMMIT 000105* /* EZESQCOD=100 1 * 100 ROLLBACK (if UROWR = 0) 000106* /* 0 COMMIT (if UROWR > 0) 000107* /* EZESQCOD=-803 * Y 104 ROLLBACK 000108* /* EZESQCOD=-803 * N 0 COMMIT 000109* /* EZESQCOD=-911 * * 108 ROLLBACK 000110* /* other SQL error * * 112 ROLLBACK 000111* 000112* /* In case an SQL error occurred: 000113* IF EZESQCOD NE 0 000114* AND VDBCONTROL.URC EQ 0; IF EZESQCOD NOT = 0 AND URC OF VDBCONTROL = 0 000115* 000116* /* No Record Found error (NRF) 000117* IF EZESQCOD EQ 100; IF EZESQCOD = 100 000118* IF VDBCONTROL.UIOTYPE EQ "D"; IF UIOTYPE OF VDBCONTROL = "D" 000119* /* Delete failed: row not found 000120* VMESSAGE.UMSGCODE = 'SQL0100D'; MOVE "SQL0100D" TO UMSGCODE OF VMESSAGE 000121* VDBCONTROL.URC = 1; MOVE 1 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000122* ELSE; ELSE 000123* IF VDBCONTROL.UIOTYPE EQ "U"; IF UIOTYPE OF VDBCONTROL = "U" 000124* /* Update failed: row not found 000125* VMESSAGE.UMSGCODE = 'SQL0100U'; MOVE "SQL0100U" TO UMSGCODE OF VMESSAGE 000126* VDBCONTROL.URC = 1; MOVE 1 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000127* ELSE; ELSE 000128* IF VDBCOMMON.UNRF EQ 'Y'; IF UNRF OF VDBCOMMON = "Y" 000129* /* Read failed: row not found 000130* VDBCONTROL.URC = 100; MOVE 100 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000131* VMESSAGE.UMSGCODE = 'SQL0100'; MOVE "SQL0100" TO UMSGCODE OF VMESSAGE 000132* ELSE; ELSE 000133* IF VDBCOMMON.UNRF EQ '1'; IF UNRF OF VDBCOMMON = "1" 000134* IF VDBCONTROL.UROWR EQ 0; IF UROWR OF VDBCONTROL = 0 000135* /* No rows read: NRF error 000136* VDBCONTROL.URC = 100; MOVE 100 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000137* VMESSAGE.UMSGCODE = 'SQL0100'; MOVE "SQL0100" TO UMSGCODE OF VMESSAGE 000138* END; END-IF 000139* END; END-IF 000140* END; END-IF 000141* END; END-IF 000142* END; END-IF 000143* ELSE; /* Other errors ELSE 000144* /* duplicate key error (DUP) 000145* IF EZESQCOD EQ -803; IF EZESQCOD = -803 000146* IF VDBCOMMON.UDUP EQ 'Y'; IF UDUP OF VDBCOMMON = "Y" 000147* VDBCONTROL.URC = 104; MOVE 104 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000148* VMESSAGE.UMSGCODE = 'SQL0803'; MOVE "SQL0803" TO UMSGCODE OF VMESSAGE 000149* END; END-IF 000150* ELSE; ELSE 000151* /* deadlock/timeout error 000152* IF EZESQCOD EQ -911 000153* OR EZESQCOD EQ -913; IF EZESQCOD = -911 OR EZESQCOD = -913 000154* VDBCONTROL.URC = 108; MOVE 108 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000155* VMESSAGE.UMSGCODE = 'SQL0913'; MOVE "SQL0913" TO UMSGCODE OF VMESSAGE 000156* ELSE; ELSE 000157* IF EZESQCOD EQ -532; IF EZESQCOD = -532 000158* VDBCONTROL.URC = 108; MOVE 108 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000159* VMESSAGE.UMSGCODE = 'SQL0532'; MOVE "SQL0532" TO UMSGCODE OF VMESSAGE 000160* ELSE; ELSE 000161* IF EZESQCOD EQ -530; IF EZESQCOD = -530 000162* VDBCONTROL.URC = 108; MOVE 108 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000163* VMESSAGE.UMSGCODE = 'SQL0530'; MOVE "SQL0530" TO UMSGCODE OF VMESSAGE 000164* ELSE; ELSE 000165* /* Other SQL error 000166* IF EZESQCOD LT 0; IF EZESQCOD < 0 000167* VDBCONTROL.URC = 112; MOVE 112 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000168* VMESSAGE.UMSGCODE = 'SQL9999'; MOVE "SQL9999" TO UMSGCODE OF VMESSAGE 000169* END; END-IF 000170* END; END-IF 000171* END; END-IF 000172* END; /* deadlock/timeout error END-IF 000173* END; /* DUP error END-IF 000174* END; /* NRF error END-IF 000175* 000176* /* When URC contains a value, move the EZESQCOD 000177* /* to the message insert field. 000178* IF VDBCONTROL.URC EQ 112 000179* OR VDBCONTROL.URC EQ 108; IF URC OF VDBCONTROL = 112 OR URC OF VDBCONTROL = 108 000180* 000181* /* Move SQL error number to number item. 000182* VDBCOMMON.USQLNUM = EZESQCOD; COMPUTE USQLNUM OF VDBCOMMON = EZESQCOD ON SIZE ERROR MOVE "SQL-ERROR" TO EZERTS-PRC-NAME MOVE 182 TO EZERTS-PRC-NUM PERFORM EZEOVER-ROUTINE END-COMPUTE CALL "ELAFXNUM" USING USQLNUM OF VDBCOMMON(LENGTH OF USQLNUM OF VDBCOMMON:1) 000183* 000184* /* Set SQL code sign. 000185* IF VDBCOMMON.USQLNUM LT 0; IF USQLNUM OF VDBCOMMON < 0 000186* VDBCOMMON.USIGN = '-'; MOVE "-" TO USIGN OF VDBCOMMON 000187* VDBCOMMON.USQLNUM = VDBCOMMON.USQLNUM * -1; COMPUTE USQLNUM OF VDBCOMMON = USQLNUM OF VDBCOMMON * -1 ON SIZE ERROR MOVE "SQL-ERROR" TO EZERTS-PRC-NAME MOVE 187 TO EZERTS-PRC-NUM PERFORM EZEOVER-ROUTINE END-COMPUTE CALL "ELAFXNUM" USING USQLNUM OF VDBCOMMON(LENGTH OF USQLNUM OF VDBCOMMON:1) 000188* ELSE; ELSE 000189* VDBCOMMON.USIGN = '+'; MOVE "+" TO USIGN OF VDBCOMMON 000190* END; /* Set SQL code sign. END-IF 000191* 000192* /* Move SQL error number to character item. 000193* VDBCOMMON.USQLCHA = VDBCOMMON.USQLNUM; MOVE USQLNUM OF VDBCOMMON(1:LENGTH OF USQLNUM OF VDBCOMMON) TO USQLCHA OF VDBCOMMON 000194* 000195* /* Move SQL error number to message insert. 000196* VMESSAGE.UMSGINS(1) = VDBCOMMON.UEZESQCD; MOVE UEZESQCD OF VDBCOMMON TO UMSGINS OF VMESSAGE (1) 000197* 000198* END; END-IF 000199* END; /* SQL error occurred. END-IF 000200* 000201* 000202* /* When error occurred: 000203* IF VDBCONTROL.URC NE 0; IF URC OF VDBCONTROL NOT = 0 000204* 000205* /* Store SQL message inserts. 000206* VDBCONTROL.UEZESQRRM = EZESQRRM; MOVE EZESQRRM TO UEZESQRRM OF VDBCONTROL 000207* 000208* /* Move applicationame to message insert. 000209* IF VMESSAGE.UMSGINS(1) EQ ' '; IF UMSGINS OF VMESSAGE (1) = " " 000210* VMESSAGE.UMSGINS(1) = VDBCOMMON.UPROCNAM; MOVE UPROCNAM OF VDBCOMMON TO UMSGINS OF VMESSAGE (1) 000211* END; END-IF 000212* 000213* /* Move applicationame to message insert. 000214* IF VMESSAGE.UMSGINS(2) EQ ' '; IF UMSGINS OF VMESSAGE (2) = " " 000215* VMESSAGE.UMSGINS(2) = VDBCOMMON.UAPPLNAM; MOVE UAPPLNAM OF VDBCOMMON TO UMSGINS OF VMESSAGE (2) 000216* END; END-IF 000217* 000218* /* Move tablename to message insert. 000219* IF VMESSAGE.UMSGINS(3) EQ ' '; IF UMSGINS OF VMESSAGE (3) = " " 000220* VMESSAGE.UMSGINS(3) = VDBCOMMON.UTABLNAM; MOVE UTABLNAM OF VDBCOMMON TO UMSGINS OF VMESSAGE (3) 000221* END; END-IF 000222* 000223* /* Determine if rollback is required 000224* IF VDBCONTROL.UACCTYP EQ 'W' 000225* AND VDBCONTROL.UROWW GE 1; IF UACCTYP OF VDBCONTROL = "W" AND UROWW OF VDBCONTROL >= 1 000226* VDBCONTROL.UROLLBACK = 'Y'; MOVE "Y" TO UROLLBACK OF VDBCONTROL 000227* END; /* Rollback required. END-IF 000228* END; /* Error detected. END-IF CONTINUE. EZE-EZEP-SQL-ERROR-X. EXIT. *----------------------------------------------------------------- * PROCESS : SQL-INIT * : SQL-INIT RENAMED TO EZEP-SQL-INIT * MODIFICATION DATE : 01.06.2000 * MODIFICATION TIME : 10:44:07 * PROCESS OPTION : EXECUTE * DESCRIPTION : std. SQL initialization *----------------------------------------------------------------- EZEP-SQL-INIT SECTION. MOVE "SQL-INIT" TO EZERTS-PRC-NAME 000229* /* ************************************************************ 000230* /* * Proces : SQL-INIT 000231* /* * 000232* /* * Function : This process initializes the record items 000233* /* * used in applications which perform SQL 000234* /* * queries. 000235* /* * 000236* /* ************************************************************ 000237* 000238* /* Return SQL hard errors. 000239* EZEFEC = 1; MOVE 1 TO EZEFEC CALL "ELAFXNUM" USING EZEFEC(LENGTH OF EZEFEC:1) 000240* 000241* /* Initialize common data items used for control 000242* /* and error handling. 000243* VDBCONTROL.URC = 0; MOVE 0 TO URC OF VDBCONTROL CALL "ELAFXNUM" USING URC OF VDBCONTROL(LENGTH OF URC OF VDBCONTROL:1) 000244* VDBCONTROL.UROLLBACK = 'N'; MOVE "N" TO UROLLBACK OF VDBCONTROL 000245* VDBCONTROL.UNRF = 'N'; MOVE "N" TO UNRF OF VDBCONTROL 000246* 000247* VDBCONTROL.UACCTYP = ' '; MOVE " " TO UACCTYP OF VDBCONTROL 000248* VDBCONTROL.UACCSAV = ' '; MOVE " " TO UACCSAV OF VDBCONTROL 000249* VDBCONTROL.UROWR = 0; MOVE 0 TO UROWR OF VDBCONTROL 000250* VDBCONTROL.UROWW = 0; MOVE 0 TO UROWW OF VDBCONTROL 000251* VDBCONTROL.UEZESQRRM = ' '; MOVE " " TO UEZESQRRM OF VDBCONTROL 000252* 000253* SET VDBCOMMON EMPTY; PERFORM EZESETEMP-VDBCOMMON 000254* 000255* LOW-VALUE = ' '; MOVE " " TO EZEI-LOW-VALUE OF VDBCONTROL 000256* IF EZESYS IS ITF; IF EZESYS-ITF 000257* HIGH-VALUE = 'Z'; MOVE "Z" TO EZEI-HIGH-VALUE OF VDBCONTROL 000258* ELSE; ELSE 000259* HIGH-VALUE = '9'; MOVE "9" TO EZEI-HIGH-VALUE OF VDBCONTROL 000260* END; END-IF 000261* CONTINUE. EZE-EZEP-SQL-INIT-X. EXIT. *----------------------------------------------------------------- * SQL ERROR ROUTINE *----------------------------------------------------------------- EZESQL-ERROR-ROUTINE SECTION. SET EZERTS-SQL-USED TO TRUE IF EZERTS-SQL-COMMAND NOT = "CLOSE" MOVE SQLCA TO EZESQLCA END-IF IF SQLCODE = 0 MOVE 0 TO EZERTS-SQLERR-STATUS ELSE MOVE EZERTS-SQLERR TO EZERTS-SQLERR-SVCS-NUM CALL "ELARSVCS" USING EZERTS-CONTROL-BLOCK EZERTS-SQLERR-REQUEST-BLOCK SQLCA IF EZERTS-TERMINATE AND EZECTL-NOT-IN-EZETERMINATE GO TO EZETERMINATE END-IF END-IF. EZESQL-ERROR-ROUTINE-X. EXIT. *----------------------------------------------------------------- * SET EMPTY FOR RECORD KATSAYI *----------------------------------------------------------------- EZESETEMP-KATSAYI SECTION. MOVE LOW-VALUES TO KATSAYI OF EZESTA-KATSAYI-GP MOVE SPACES TO EZEI-1 OF KATSAYI MOVE 0 TO EZEI-5 OF KATSAYI MOVE 0 TO EZEI-7 OF KATSAYI MOVE 0 TO EZEI-9 OF KATSAYI MOVE 0 TO EZEI-11 OF KATSAYI MOVE 0 TO EZEI-13 OF KATSAYI CONTINUE. EZESETEMP-KATSAYI-X. EXIT. *----------------------------------------------------------------- * SET EMPTY FOR RECORD VDBCOMMON *----------------------------------------------------------------- EZESETEMP-VDBCOMMON SECTION. INITIALIZE VDBCOMMON OF EZEWS-VDBCOMMON-GP MOVE SPACES TO USYSID1 OF VDBCOMMON MOVE SPACES TO UAPPLID OF VDBCOMMON MOVE SPACES TO UAPPLSFX OF VDBCOMMON CALL "ELAFXNUM" USING USQLNUM OF VDBCOMMON(LENGTH OF USQLNUM OF VDBCOMMON:1) MOVE SPACES TO USIGN OF VDBCOMMON MOVE SPACES TO USQLCHA OF VDBCOMMON CONTINUE. EZESETEMP-VDBCOMMON-X. EXIT. *----------------------------------------------------------------- * TERMINATION LOGIC *----------------------------------------------------------------- EZETERMINATE SECTION. SET EZECTL-IN-EZETERMINATE TO TRUE. MOVE "EZETERMINATE" TO EZERTS-PRC-NAME PERFORM EZERESRC-SCHEDULE GO TO EZERUN-PROCESSES-X. *----------------------------------------------------------------- * ARITHMETIC OVERFLOW ROUTINE *----------------------------------------------------------------- EZEOVER-ROUTINE SECTION. MOVE 1 TO EZEOVERS IF EZEOVER-TERMINATE MOVE 0009 TO EZERTS-ERROR-NUM CALL "ELARSVCS" USING EZERTS-CONTROL-BLOCK EZERTS-ERROR-REQUEST-BLOCK GO TO EZETERMINATE END-IF. EZEOVER-ROUTINE-X. EXIT. *----------------------------------------------------------------- * MAXIMUM VALUE OVERFLOW ROUTINE *----------------------------------------------------------------- EZEOVER-MAX-VALUE-ROUTINE SECTION. MOVE 1 TO EZEOVERS IF EZEOVER-DEFAULT OR EZEOVER-TERMINATE MOVE 0026 TO EZERTS-ERROR-NUM CALL "ELARSVCS" USING EZERTS-CONTROL-BLOCK EZERTS-ERROR-REQUEST-BLOCK GO TO EZETERMINATE END-IF. EZEOVER-MAX-VALUE-ROUTINE-X. EXIT. *----------------------------------------------------------------- * CALLED APPLICATION CONTROL LOGIC *----------------------------------------------------------------- EZECONTROL SECTION. MOVE EIBFN TO EZEAPP-ENTRY-FUNCTION EXEC CICS IGNORE CONDITION ERROR END-EXEC CALL "ELARSTWA" USING DFHEIBLK DFHCOMMAREA EZEAPP-PROFILE SET ADDRESS OF EZERTS-CONTROL-BLOCK TO EZEAPP-RTS-PTR EXEC CICS HANDLE ABEND PROGRAM("ELAESABD") END-EXEC SET EZEPARM-MAPS-INVALID TO TRUE IF NOT EZERTS-SET MOVE "EZEINITIALIZE" TO EZERTS-PRC-NAME MOVE EZEAPP-APPL-NAME TO EZERTS-PGM-NAME SET EZEAPP-CALLER-PROFILE TO NULL CALL "ELAASADR" USING EZEAPP-PROFILE EZERTS-INIT-PROFILE ELSE MOVE "EZEINITIALIZE" TO EZERTS-PRC-NAME MOVE EZERTS-PGM-NAME TO EZECALLER MOVE EZEAPP-APPL-NAME TO EZERTS-PGM-NAME SET EZEAPP-CALLER-PROFILE TO EZERTS-CURR-PROFILE MOVE EZEDLPSB TO EZECTL-HOLD-EZEDLPSB IF EZERTS-TERMINATE CALL "ELAASADR" USING EZEAPP-PROFILE EZERTS-CURR-PROFILE SET EZECTL-IN-EZETERMINATE TO TRUE PERFORM EZEAPPL-IDENTIFY PERFORM EZEEXTERNAL-INITIALIZATION PERFORM EZERESRC-CLEANUP SET EZERTS-CURR-PROFILE TO EZEAPP-CALLER-PROFILE MOVE EZECALLER TO EZERTS-PGM-NAME GO TO EZECONTROL-X END-IF END-IF MOVE EZERTS-CTL-MODE TO EZECTL-HOLD-CTL-MODE MOVE EZERTS-CTL-REQUEST TO EZECTL-HOLD-CTL-REQUEST MOVE EZESEGTR TO EZESEGTR-SAVE MOVE SPACES TO EZESEGTR PERFORM EZEAPPL-IDENTIFY PERFORM EZEINITIALIZE-STORAGE PERFORM EZEREFRESH-STORAGE IF NOT EZERTS-TERMINATE-ON-ERROR AND EZEAPP-ENTRY-FUNCTION NOT = X"0E04" AND NOT EZERTS-ENTRY-FROM-TSMODULE PERFORM EZERECEIVE-COMMAREA-PARMS END-IF IF NOT EZERTS-TERMINATE-ON-ERROR PERFORM EZEEXTERNAL-INITIALIZATION END-IF IF NOT EZERTS-TERMINATE-ON-ERROR PERFORM EZERUN-PROCESSES END-IF IF EZEAPP-CALLER-PROFILE = NULL OR EZEAPP-ENTRY-FUNCTION = X"0E04" OR EZERTS-ENTRY-FROM-TSMODULE SET EZEAPP-CALLER-PROFILE TO NULL IF EZERTS-TERMINATE-ON-ERROR PERFORM EZEREPORT-ERRS-ON-TERMINATN END-IF PERFORM EZECICS-RTS-TERMINATE ELSE SET EZERTS-CURR-PROFILE TO EZEAPP-CALLER-PROFILE MOVE EZECALLER TO EZERTS-PGM-NAME MOVE EZESEGTR-SAVE TO EZESEGTR IF NOT EZERTS-TERMINATE MOVE EZECTL-HOLD-CTL-MODE TO EZERTS-CTL-MODE MOVE EZECTL-HOLD-CTL-REQUEST TO EZERTS-CTL-REQUEST END-IF MOVE EZECTL-HOLD-EZEDLPSB TO EZEDLPSB END-IF. EZECONTROL-X. EXIT. *----------------------------------------------------------------- * IDENTIFY APPLICATION *----------------------------------------------------------------- EZEAPPL-IDENTIFY SECTION. IF NOT EZERTS-SET MOVE SPACES TO EZELTERM MOVE ALL "*" TO EZEUSR EZEUSRID END-IF SET EZEAPP-CURS-BLK-PTR TO NULL SET EZEAPP-LAST-MAPBUF-PTR TO NULL SET EZEAPP-FIRST-MAPBUF-PTR TO NULL SET EZEAPP-ROWS-USED-PTR TO NULL SET EZEAPP-MAPG-MOD-PTR TO NULL SET EZEAPP-HELPG-MOD-PTR TO NULL CALL "ELAASADR" USING EZEWORDS EZEAPP-EZE-WORDS-PTR CALL "ELAASADR" USING EZEPARM-VALIDATION EZEAPP-PARM-VAL-PTR CALL "ELAASADR" USING EZEAPP-PROFILE EZERTS-CURR-PROFILE. EZEAPPL-IDENTIFY-X. EXIT. *----------------------------------------------------------------- * INITIALIZE STORAGE *----------------------------------------------------------------- EZEINITIALIZE-STORAGE SECTION. MOVE SPACES TO EZEWORDS-I MOVE ZERO TO EZECNVCM MOVE ZERO TO EZEFEC EZERCODE MOVE ZERO TO EZEDLERR EZESQISL EZEOVER EZEOVERS MOVE SPACES TO EZEDLPSB IF EZESEGTR = LOW-VALUES MOVE EIBTRNID TO EZESEGTR END-IF MOVE EIBTRMID TO EZELTERM EZEUSR SET EZESEGM-DEFINED TO TRUE MOVE SPACES TO EZEDESTP MOVE "N" TO EZEAPP-EZEDESTP-DIFF MOVE "N" TO EZEAPP-EZEDESTP-CHANGED MOVE 0 TO EZESTA-KATSAYI-RC PERFORM EZESETEMP-KATSAYI PERFORM EZESETEMP-VDBCOMMON CONTINUE. EZEINITIALIZE-STORAGE-X. EXIT. *----------------------------------------------------------------- * REFRESH STORAGE - ONLY THESE FIELDS ARE RESET ACROSS CONVERSE *----------------------------------------------------------------- EZEREFRESH-STORAGE SECTION. MOVE ZERO TO EZEDLCER EZEDLCON MOVE ZERO TO EZETST EZEDLLEV EZEDLSSG MOVE ZERO TO EZEMNO EZEDLKYL MOVE SPACES TO EZEDLSTC EZEDLDBD EZEDLKEY EZEDLPRO EZEDLSEG MOVE SPACES TO EZEMSG OF EZEWORDS MOVE "N" TO EZEMNO-MSG-FILE-SW MOVE LOW-VALUES TO EZESQLCA MOVE "SQLCA" TO EZESQNAM MOVE +136 TO EZESQABC MOVE ZERO TO EZESQCOD EZESQRRL MOVE ZERO TO EZESQRD1 EZESQRD2 EZESQRD3 MOVE ZERO TO EZESQRD4 EZESQRD5 EZESQRD6 IF NOT EZERTS-SET OR NOT EZERTS-TERMINATE MOVE SPACES TO EZERTS-DXFR-APPLID SET EZERTS-XFER-MAP-PTR TO NULL SET EZERTS-DXFR-XFER-REC-PTR TO NULL MOVE ZERO TO EZERTS-DXFR-XFER-REC-LEN END-IF. EZEREFRESH-STORAGE-X. EXIT. *----------------------------------------------------------------- * RTS INITIALIZATION *----------------------------------------------------------------- EZEEXTERNAL-INITIALIZATION SECTION. CALL "ELARSINT" USING EZERTS-CONTROL-BLOCK IF EZERTS-TERMINATE-ON-ERROR AND EZECTL-NOT-IN-EZETERMINATE GO TO EZEEXTERNAL-INITIALIZATION-X END-IF SET ADDRESS OF EZEIOP-NLS-INDEP-CTL-BLOCK TO EZERTS-IOP-TABLE-PTR SET ADDRESS OF EZEIOE-NLS-DEP-CTL-BLOCK TO EZERTS-DOP-TABLE-PTR SET ADDRESS OF EZECRS-CURSOR-BLOCKS TO EZEAPP-CURS-BLK-PTR IF NOT EZERTS-TERMINATE SET EZERTS-EXECUTE TO TRUE END-IF. EZEEXTERNAL-INITIALIZATION-X. EXIT. *----------------------------------------------------------------- * RUN APPLICATION PROCESSES *----------------------------------------------------------------- EZERUN-PROCESSES SECTION. SET EZECTL-NOT-IN-EZETERMINATE TO TRUE GO TO EZEBEGIN-PROCESSES. EZERUN-PROCESSES-X. EXIT. *----------------------------------------------------------------- * REPORT THE ERRORS *----------------------------------------------------------------- EZEREPORT-ERRS-ON-TERMINATN SECTION. IF NOT EZERTS-ROLLBACK-TAKEN SET EZERTS-ROLLBACK-TAKEN TO TRUE MOVE EZERTS-ROLLBACK TO EZERTS-SVCS-NUM CALL "ELARSVCS" USING EZERTS-CONTROL-BLOCK EZERTS-REQUEST-BLOCK END-IF IF EZERTS-TERMINAL-ATTACHED MOVE EZERTS-DISPLAY-ERROR-MAP TO EZERTS-SVCS-NUM CALL "ELARSVCS" USING EZERTS-CONTROL-BLOCK EZERTS-REQUEST-BLOCK END-IF CONTINUE. EZEREPORT-ERRS-ON-TERMINATN-X. EXIT. *----------------------------------------------------------------- * RECEIVE PARAMETERS THAT WERE PASSED IN THE COMMAREA *----------------------------------------------------------------- EZERECEIVE-COMMAREA-PARMS SECTION. IF EIBCALEN < 4 OR (DFHCOMMAREA(EIBCALEN - 3:4) = HIGH-VALUES AND EIBCALEN NOT = 16) OR (DFHCOMMAREA(EIBCALEN - 3:4) NOT = HIGH-VALUES AND EIBCALEN NOT = 12) IF NOT EZERTS-SET CALL "ELARSINT" USING EZERTS-CONTROL-BLOCK END-IF IF NOT EZERTS-TERMINATE MOVE 32 TO EZERTS-ERROR-NUM CALL "ELARSVCS" USING EZERTS-CONTROL-BLOCK EZERTS-ERROR-REQUEST-BLOCK END-IF GO TO EZERECEIVE-COMMAREA-PARMS-X END-IF SET ADDRESS OF EZERCD-WKATSAYI-GP TO EZECOMMAREA-PTR(1) SET ADDRESS OF EZERCD-VDBCONTROL-GP TO EZECOMMAREA-PTR(2) SET ADDRESS OF EZERCD-VMESSAGE-GP TO EZECOMMAREA-PTR(3) CONTINUE. EZERECEIVE-COMMAREA-PARMS-X. EXIT. *----------------------------------------------------------------- * CANCEL CLEAN-UP IF ALL RESOURCES ARE CLOSED *----------------------------------------------------------------- EZERESRC-SCHEDULE SECTION. MOVE "EZERESRC-SCHED" TO EZERTS-PRC-NAME IF EZEAPP-CALLER-PROFILE IS EQUAL TO NULL PERFORM EZERESRC-CLEANUP GO TO EZERESRC-SCHEDULE-X END-IF IF EZECRS-KATSAYI-CLOS MOVE EZERTS-UNSCHEDULE TO EZERTS-SVCS-NUM CALL "ELARSVCS" USING EZERTS-CONTROL-BLOCK EZERTS-REQUEST-BLOCK END-IF CONTINUE. EZERESRC-SCHEDULE-X. EXIT. *----------------------------------------------------------------- * RESOURCE CLEAN-UP ROUTINE *----------------------------------------------------------------- EZERESRC-CLEANUP SECTION. SET EZECTL-IN-EZETERMINATE TO TRUE MOVE "EZERESRC-CLEAN" TO EZERTS-PRC-NAME PERFORM EZERESRC-CLOSE-CURSORS CONTINUE. EZERESRC-CLEANUP-X. EXIT. *----------------------------------------------------------------- * RESOURCE CLEAN-UP / CLOSE ALL OPEN CURSORS *----------------------------------------------------------------- EZERESRC-CLOSE-CURSORS SECTION. IF NOT EZECRS-KATSAYI-CLOS PERFORM EZECLOSCU-KATSAYI END-IF CONTINUE. EZERESRC-CLOSE-CURSORS-X. EXIT. EZECICS-RTS-TERMINATE SECTION. CALL "ELAASTRM" USING EZERTS-CONTROL-BLOCK EZERTS-REQUEST-BLOCK EXEC CICS HANDLE ABEND CANCEL END-EXEC. EZECICS-RTS-TERMINATE-X. EXIT. *----------------------------------------------------------------- * END OF PROGRAM KGGSM1 *-----------------------------------------------------------------